Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DO NOT MERGE] Proposed spikes for JSLB4 #2404

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
60 changes: 60 additions & 0 deletions jslb4-spikes.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
Here is the proposal for the followup tasks for
https://github.com/strongloop/loopback-next/issues/1978. Anything needs to be
clarified or you'd like to be added, do let me know.

**1. Spike: Dependency injection or its alternative in JSLB4**

_Acceptance criteria:_

a. Should be demonstrated in a class b. Should be used with
[JSLB4 Application class](https://github.com/strongloop/loopback4-example-javascript/blob/class-factory/server/application.js)
c. Should be able to read properties from the LB4 `context` d. Should be able to
bind new properties the LB4 `context` e. Should be able to unbind properties
from the LB4 `context`

**2. Spike: Create Route in JSLB4**

_Acceptance criteria:_

a. Should be created as a class b. Should be useable with
[JSLB4 Application class](https://github.com/strongloop/loopback4-example-javascript/blob/class-factory/server/application.js)
c. Should have access to: i. The LB4 request object and metadata contributed by
LB4 components eg: `@loopback/authentication` ii. A Model iii. The LB4 response
object

**3. Spike: Create Sequence in JSLB4**

_Acceptance criteria:_

a. Should be created as a class b. Demonstrate usage with
[JSLB4 Application class](https://github.com/strongloop/loopback4-example-javascript/blob/class-factory/server/application.js)

**4. Spike: Create Model in JSLB4**

_Acceptance criteria:_

a. Should be created as a class b. Should be automatically loaded in the LB4 app
c. Should be able to describe model properties d. Should show up on Explorer and
should be successfully interactive

**5. Spike: Create Repository in JSLB4**

_Acceptance criteria:_

a. Should be created as a class b. Should be automatically loaded in the LB4 app
c. Should have access to a specified Model d. Should expose CRUD methods to
interact with the Model e. Should allow custom methods to be added, with access
to: i. The LB4 request object ii. A Model

**6. Spike: Create Controller in JSLB4**

_Acceptance criteria:_

a. Should be created as a class b. Should be automatically loaded in the LB4 app
c. Should have access to a specified Repository d. Should expose CRUD methods to
interact with the Repository e. Should allow custom methods to be added, with
access to: i. The LB4 request object ii. A Model iii. A Repository iv. The LB4
response object

I think, once **Spike 1** is sorted out, everything else will come along
smoothly.