-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Clean up extension template and docs #5336
Comments
@bajtos |
Also, why call it "Extension" when we are creating a Component? Can we name the command |
|
I would like to reserve |
I have no idea, TBH. I believe this behavior was introduced by @raymondfeng, please check with him. Also, have you checked the discussion in the pull request introducing
In my view, the term "component" includes both built-in components (e.g. context & TS decorator metadata) and add-on components/extensions (e.g. On the other hand, "extension" is for things that are outside of the "core" framework. In loopback-next, we have a top-level directory If you want to unify our vocabulary and use a single term (which I think is a great idea!), then IMO we should use "extension", not "component". IIRC, we started to use the term "component" early in LB4 development. Later we pivoted to use "extension", but we did not propagate that change to existing docs. |
Created this follow up task - #6232. |
Closed via #6158. |
This is a follow-up for #5337 and #5122
The documentation for component authors (e.g. Creating components) and the template used by
lb4 extension
are outdated. We learned a lot since those artifacts were written and introduced new conventions and features, e.g.@config
decorator. It's time to modernize both the CLI template and the docs to the latest and greatest.Acceptance criteria
CLI templates
Update the template used by
lb4 extension
to follow the current style as seen e.g. inextensions/metrics
src/keys.ts
exporting{ComponentName}Keys.COMPONENT
binding key@bind()
,Nice to have:
src/{name}.keys.ts
andsrc/{name}.component.ts
Docs
Revisit the documentation, make it consistent with the current style for writing extensions and the CLI template.
@config
andthis.configure()
APIextensions
andpackages
)Nice to have:
The text was updated successfully, but these errors were encountered: