@linyjs/plugin-docs 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +97 -0
- package/docs/api-reference/index.md +341 -0
- package/docs/best-practices/error-handling.md +462 -0
- package/docs/best-practices/naming-conventions.md +495 -0
- package/docs/best-practices/performance.md +532 -0
- package/docs/best-practices/security.md +620 -0
- package/docs/faq.md +323 -0
- package/docs/getting-started/first-plugin.md +358 -0
- package/docs/getting-started/installation.md +244 -0
- package/docs/getting-started/quick-start.md +174 -0
- package/docs/guides/client-module.md +598 -0
- package/docs/guides/data-persistence.md +536 -0
- package/docs/guides/permissions.md +440 -0
- package/docs/guides/server-module.md +371 -0
- package/docs/guides/ui-slots.md +475 -0
- package/docs/migration/v0-to-v1.md +354 -0
- package/examples/analytics-plugin/README.md +416 -0
- package/examples/analytics-plugin/dist/client/index.d.ts +36 -0
- package/examples/analytics-plugin/dist/client/index.js +173 -0
- package/examples/analytics-plugin/dist/index.d.ts +64 -0
- package/examples/analytics-plugin/dist/index.js +72 -0
- package/examples/analytics-plugin/dist/server/index.d.ts +119 -0
- package/examples/analytics-plugin/dist/server/index.js +313 -0
- package/examples/analytics-plugin/package.json +28 -0
- package/examples/analytics-plugin/src/client/index.tsx +410 -0
- package/examples/analytics-plugin/src/index.ts +71 -0
- package/examples/analytics-plugin/src/server/index.ts +348 -0
- package/examples/analytics-plugin/tsconfig.json +21 -0
- package/examples/blog-plugin/README.md +316 -0
- package/examples/blog-plugin/dist/client/index.d.ts +22 -0
- package/examples/blog-plugin/dist/client/index.js +197 -0
- package/examples/blog-plugin/dist/server/index.d.ts +5 -0
- package/examples/blog-plugin/dist/server/index.js +220 -0
- package/examples/blog-plugin/package.json +24 -0
- package/examples/blog-plugin/src/client/index.tsx +405 -0
- package/examples/blog-plugin/src/server/index.ts +240 -0
- package/examples/blog-plugin/tsconfig.json +16 -0
- package/examples/hello-world/README.md +101 -0
- package/examples/hello-world/dist/client/index.d.ts +5 -0
- package/examples/hello-world/dist/client/index.js +80 -0
- package/examples/hello-world/dist/server/index.d.ts +5 -0
- package/examples/hello-world/dist/server/index.js +38 -0
- package/examples/hello-world/node_modules/.package-lock.json +61 -0
- package/examples/hello-world/node_modules/@linyjs/client-module-interface/HOOKS_USAGE.md +281 -0
- package/examples/hello-world/node_modules/@linyjs/client-module-interface/IMPLEMENTATION_SUMMARY.md +166 -0
- package/examples/hello-world/node_modules/@linyjs/client-module-interface/QUICK_REFERENCE.md +130 -0
- package/examples/hello-world/node_modules/@linyjs/client-module-interface/README.md +214 -0
- package/examples/hello-world/node_modules/@linyjs/client-module-interface/package.json +26 -0
- package/examples/hello-world/node_modules/@linyjs/client-module-interface/src/application.ts +50 -0
- package/examples/hello-world/node_modules/@linyjs/client-module-interface/src/comparison-example.tsx +229 -0
- package/examples/hello-world/node_modules/@linyjs/client-module-interface/src/di.ts +127 -0
- package/examples/hello-world/node_modules/@linyjs/client-module-interface/src/domain.ts +52 -0
- package/examples/hello-world/node_modules/@linyjs/client-module-interface/src/hooks-example.tsx +275 -0
- package/examples/hello-world/node_modules/@linyjs/client-module-interface/src/hooks.ts +175 -0
- package/examples/hello-world/node_modules/@linyjs/client-module-interface/src/index.ts +87 -0
- package/examples/hello-world/node_modules/@linyjs/client-module-interface/src/interfaces.ts +117 -0
- package/examples/hello-world/node_modules/@linyjs/client-module-interface/src/router.ts +49 -0
- package/examples/hello-world/node_modules/@linyjs/client-module-interface/tsconfig.json +10 -0
- package/examples/hello-world/node_modules/@linyjs/server-module-interface/package.json +21 -0
- package/examples/hello-world/node_modules/@linyjs/server-module-interface/src/application.ts +21 -0
- package/examples/hello-world/node_modules/@linyjs/server-module-interface/src/di.ts +127 -0
- package/examples/hello-world/node_modules/@linyjs/server-module-interface/src/domain.ts +75 -0
- package/examples/hello-world/node_modules/@linyjs/server-module-interface/src/index.ts +55 -0
- package/examples/hello-world/node_modules/@linyjs/server-module-interface/src/interfaces.ts +58 -0
- package/examples/hello-world/node_modules/@linyjs/server-module-interface/tsconfig.json +8 -0
- package/examples/hello-world/node_modules/@types/react/LICENSE +21 -0
- package/examples/hello-world/node_modules/@types/react/README.md +15 -0
- package/examples/hello-world/node_modules/@types/react/canary.d.ts +129 -0
- package/examples/hello-world/node_modules/@types/react/compiler-runtime.d.ts +4 -0
- package/examples/hello-world/node_modules/@types/react/experimental.d.ts +184 -0
- package/examples/hello-world/node_modules/@types/react/global.d.ts +166 -0
- package/examples/hello-world/node_modules/@types/react/index.d.ts +4369 -0
- package/examples/hello-world/node_modules/@types/react/jsx-dev-runtime.d.ts +33 -0
- package/examples/hello-world/node_modules/@types/react/jsx-runtime.d.ts +24 -0
- package/examples/hello-world/node_modules/@types/react/package.json +210 -0
- package/examples/hello-world/node_modules/@types/react/ts5.0/canary.d.ts +129 -0
- package/examples/hello-world/node_modules/@types/react/ts5.0/experimental.d.ts +184 -0
- package/examples/hello-world/node_modules/@types/react/ts5.0/global.d.ts +166 -0
- package/examples/hello-world/node_modules/@types/react/ts5.0/index.d.ts +4356 -0
- package/examples/hello-world/node_modules/@types/react/ts5.0/jsx-dev-runtime.d.ts +33 -0
- package/examples/hello-world/node_modules/@types/react/ts5.0/jsx-runtime.d.ts +24 -0
- package/examples/hello-world/node_modules/csstype/LICENSE +19 -0
- package/examples/hello-world/node_modules/csstype/README.md +291 -0
- package/examples/hello-world/node_modules/csstype/index.d.ts +22569 -0
- package/examples/hello-world/node_modules/csstype/index.js.flow +6863 -0
- package/examples/hello-world/node_modules/csstype/package.json +70 -0
- package/examples/hello-world/node_modules/react/LICENSE +21 -0
- package/examples/hello-world/node_modules/react/README.md +37 -0
- package/examples/hello-world/node_modules/react/cjs/react-compiler-runtime.development.js +24 -0
- package/examples/hello-world/node_modules/react/cjs/react-compiler-runtime.production.js +16 -0
- package/examples/hello-world/node_modules/react/cjs/react-compiler-runtime.profiling.js +16 -0
- package/examples/hello-world/node_modules/react/cjs/react-jsx-dev-runtime.development.js +338 -0
- package/examples/hello-world/node_modules/react/cjs/react-jsx-dev-runtime.production.js +14 -0
- package/examples/hello-world/node_modules/react/cjs/react-jsx-dev-runtime.profiling.js +14 -0
- package/examples/hello-world/node_modules/react/cjs/react-jsx-dev-runtime.react-server.development.js +370 -0
- package/examples/hello-world/node_modules/react/cjs/react-jsx-dev-runtime.react-server.production.js +40 -0
- package/examples/hello-world/node_modules/react/cjs/react-jsx-runtime.development.js +352 -0
- package/examples/hello-world/node_modules/react/cjs/react-jsx-runtime.production.js +34 -0
- package/examples/hello-world/node_modules/react/cjs/react-jsx-runtime.profiling.js +34 -0
- package/examples/hello-world/node_modules/react/cjs/react-jsx-runtime.react-server.development.js +370 -0
- package/examples/hello-world/node_modules/react/cjs/react-jsx-runtime.react-server.production.js +40 -0
- package/examples/hello-world/node_modules/react/cjs/react.development.js +1284 -0
- package/examples/hello-world/node_modules/react/cjs/react.production.js +542 -0
- package/examples/hello-world/node_modules/react/cjs/react.react-server.development.js +848 -0
- package/examples/hello-world/node_modules/react/cjs/react.react-server.production.js +423 -0
- package/examples/hello-world/node_modules/react/compiler-runtime.js +14 -0
- package/examples/hello-world/node_modules/react/index.js +7 -0
- package/examples/hello-world/node_modules/react/jsx-dev-runtime.js +7 -0
- package/examples/hello-world/node_modules/react/jsx-dev-runtime.react-server.js +7 -0
- package/examples/hello-world/node_modules/react/jsx-runtime.js +7 -0
- package/examples/hello-world/node_modules/react/jsx-runtime.react-server.js +7 -0
- package/examples/hello-world/node_modules/react/package.json +51 -0
- package/examples/hello-world/node_modules/react/react.react-server.js +7 -0
- package/examples/hello-world/node_modules/typescript/LICENSE.txt +55 -0
- package/examples/hello-world/node_modules/typescript/README.md +50 -0
- package/examples/hello-world/node_modules/typescript/SECURITY.md +41 -0
- package/examples/hello-world/node_modules/typescript/ThirdPartyNoticeText.txt +193 -0
- package/examples/hello-world/node_modules/typescript/bin/tsc +2 -0
- package/examples/hello-world/node_modules/typescript/bin/tsserver +2 -0
- package/examples/hello-world/node_modules/typescript/lib/_tsc.js +133818 -0
- package/examples/hello-world/node_modules/typescript/lib/_tsserver.js +659 -0
- package/examples/hello-world/node_modules/typescript/lib/_typingsInstaller.js +222 -0
- package/examples/hello-world/node_modules/typescript/lib/cs/diagnosticMessages.generated.json +2122 -0
- package/examples/hello-world/node_modules/typescript/lib/de/diagnosticMessages.generated.json +2122 -0
- package/examples/hello-world/node_modules/typescript/lib/es/diagnosticMessages.generated.json +2122 -0
- package/examples/hello-world/node_modules/typescript/lib/fr/diagnosticMessages.generated.json +2122 -0
- package/examples/hello-world/node_modules/typescript/lib/it/diagnosticMessages.generated.json +2122 -0
- package/examples/hello-world/node_modules/typescript/lib/ja/diagnosticMessages.generated.json +2122 -0
- package/examples/hello-world/node_modules/typescript/lib/ko/diagnosticMessages.generated.json +2122 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.d.ts +22 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.decorators.d.ts +384 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.decorators.legacy.d.ts +22 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.dom.asynciterable.d.ts +41 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.dom.d.ts +39429 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.dom.iterable.d.ts +571 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2015.collection.d.ts +147 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2015.core.d.ts +597 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2015.d.ts +28 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2015.generator.d.ts +77 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2015.iterable.d.ts +605 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2015.promise.d.ts +81 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2015.proxy.d.ts +128 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2015.reflect.d.ts +144 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2015.symbol.d.ts +46 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts +326 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2016.array.include.d.ts +116 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2016.d.ts +21 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2016.full.d.ts +23 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2016.intl.d.ts +31 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2017.arraybuffer.d.ts +21 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2017.d.ts +26 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2017.date.d.ts +31 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2017.full.d.ts +23 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2017.intl.d.ts +44 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2017.object.d.ts +49 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts +135 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2017.string.d.ts +45 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2017.typedarrays.d.ts +53 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts +77 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2018.asynciterable.d.ts +53 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2018.d.ts +24 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2018.full.d.ts +24 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2018.intl.d.ts +83 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2018.promise.d.ts +30 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2018.regexp.d.ts +37 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2019.array.d.ts +79 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2019.d.ts +24 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2019.full.d.ts +24 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2019.intl.d.ts +23 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2019.object.d.ts +33 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2019.string.d.ts +37 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2019.symbol.d.ts +24 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2020.bigint.d.ts +765 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2020.d.ts +27 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2020.date.d.ts +42 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2020.full.d.ts +24 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2020.intl.d.ts +474 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2020.number.d.ts +28 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2020.promise.d.ts +47 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts +99 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2020.string.d.ts +44 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts +41 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2021.d.ts +23 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2021.full.d.ts +24 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2021.intl.d.ts +166 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2021.promise.d.ts +48 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2021.string.d.ts +33 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2021.weakref.d.ts +78 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2022.array.d.ts +121 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2022.d.ts +25 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2022.error.d.ts +75 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2022.full.d.ts +24 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2022.intl.d.ts +145 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2022.object.d.ts +26 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2022.regexp.d.ts +39 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2022.string.d.ts +25 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2023.array.d.ts +924 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2023.collection.d.ts +21 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2023.d.ts +22 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2023.full.d.ts +24 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2023.intl.d.ts +56 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2024.arraybuffer.d.ts +65 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2024.collection.d.ts +29 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2024.d.ts +26 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2024.full.d.ts +24 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2024.object.d.ts +29 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2024.promise.d.ts +35 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2024.regexp.d.ts +25 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2024.sharedmemory.d.ts +68 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es2024.string.d.ts +29 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es5.d.ts +4601 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.es6.d.ts +23 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.esnext.array.d.ts +35 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.esnext.collection.d.ts +96 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.esnext.d.ts +29 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.esnext.decorators.d.ts +28 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.esnext.disposable.d.ts +193 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.esnext.error.d.ts +24 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.esnext.float16.d.ts +445 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.esnext.full.d.ts +24 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.esnext.intl.d.ts +21 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.esnext.iterator.d.ts +148 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.esnext.promise.d.ts +34 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.esnext.sharedmemory.d.ts +25 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.scripthost.d.ts +322 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.webworker.asynciterable.d.ts +41 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.webworker.d.ts +13150 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.webworker.importscripts.d.ts +23 -0
- package/examples/hello-world/node_modules/typescript/lib/lib.webworker.iterable.d.ts +340 -0
- package/examples/hello-world/node_modules/typescript/lib/pl/diagnosticMessages.generated.json +2122 -0
- package/examples/hello-world/node_modules/typescript/lib/pt-br/diagnosticMessages.generated.json +2122 -0
- package/examples/hello-world/node_modules/typescript/lib/ru/diagnosticMessages.generated.json +2122 -0
- package/examples/hello-world/node_modules/typescript/lib/tr/diagnosticMessages.generated.json +2122 -0
- package/examples/hello-world/node_modules/typescript/lib/tsc.js +8 -0
- package/examples/hello-world/node_modules/typescript/lib/tsserver.js +8 -0
- package/examples/hello-world/node_modules/typescript/lib/tsserverlibrary.d.ts +17 -0
- package/examples/hello-world/node_modules/typescript/lib/tsserverlibrary.js +21 -0
- package/examples/hello-world/node_modules/typescript/lib/typesMap.json +497 -0
- package/examples/hello-world/node_modules/typescript/lib/typescript.d.ts +11437 -0
- package/examples/hello-world/node_modules/typescript/lib/typescript.js +200276 -0
- package/examples/hello-world/node_modules/typescript/lib/typingsInstaller.js +8 -0
- package/examples/hello-world/node_modules/typescript/lib/watchGuard.js +53 -0
- package/examples/hello-world/node_modules/typescript/lib/zh-cn/diagnosticMessages.generated.json +2122 -0
- package/examples/hello-world/node_modules/typescript/lib/zh-tw/diagnosticMessages.generated.json +2122 -0
- package/examples/hello-world/node_modules/typescript/package.json +120 -0
- package/examples/hello-world/package-lock.json +74 -0
- package/examples/hello-world/package.json +23 -0
- package/examples/hello-world/src/client/index.tsx +110 -0
- package/examples/hello-world/src/server/index.ts +42 -0
- package/examples/hello-world/tsconfig.json +16 -0
- package/package.json +42 -0
- package/src/cli.ts +321 -0
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "typescript",
|
|
3
|
+
"author": "Microsoft Corp.",
|
|
4
|
+
"homepage": "https://www.typescriptlang.org/",
|
|
5
|
+
"version": "5.9.3",
|
|
6
|
+
"license": "Apache-2.0",
|
|
7
|
+
"description": "TypeScript is a language for application scale JavaScript development",
|
|
8
|
+
"keywords": [
|
|
9
|
+
"TypeScript",
|
|
10
|
+
"Microsoft",
|
|
11
|
+
"compiler",
|
|
12
|
+
"language",
|
|
13
|
+
"javascript"
|
|
14
|
+
],
|
|
15
|
+
"bugs": {
|
|
16
|
+
"url": "https://github.com/microsoft/TypeScript/issues"
|
|
17
|
+
},
|
|
18
|
+
"repository": {
|
|
19
|
+
"type": "git",
|
|
20
|
+
"url": "https://github.com/microsoft/TypeScript.git"
|
|
21
|
+
},
|
|
22
|
+
"main": "./lib/typescript.js",
|
|
23
|
+
"typings": "./lib/typescript.d.ts",
|
|
24
|
+
"bin": {
|
|
25
|
+
"tsc": "./bin/tsc",
|
|
26
|
+
"tsserver": "./bin/tsserver"
|
|
27
|
+
},
|
|
28
|
+
"engines": {
|
|
29
|
+
"node": ">=14.17"
|
|
30
|
+
},
|
|
31
|
+
"files": [
|
|
32
|
+
"bin",
|
|
33
|
+
"lib",
|
|
34
|
+
"!lib/enu",
|
|
35
|
+
"LICENSE.txt",
|
|
36
|
+
"README.md",
|
|
37
|
+
"SECURITY.md",
|
|
38
|
+
"ThirdPartyNoticeText.txt",
|
|
39
|
+
"!**/.gitattributes"
|
|
40
|
+
],
|
|
41
|
+
"devDependencies": {
|
|
42
|
+
"@dprint/formatter": "^0.4.1",
|
|
43
|
+
"@dprint/typescript": "0.93.4",
|
|
44
|
+
"@esfx/canceltoken": "^1.0.0",
|
|
45
|
+
"@eslint/js": "^9.20.0",
|
|
46
|
+
"@octokit/rest": "^21.1.1",
|
|
47
|
+
"@types/chai": "^4.3.20",
|
|
48
|
+
"@types/diff": "^7.0.1",
|
|
49
|
+
"@types/minimist": "^1.2.5",
|
|
50
|
+
"@types/mocha": "^10.0.10",
|
|
51
|
+
"@types/ms": "^0.7.34",
|
|
52
|
+
"@types/node": "latest",
|
|
53
|
+
"@types/source-map-support": "^0.5.10",
|
|
54
|
+
"@types/which": "^3.0.4",
|
|
55
|
+
"@typescript-eslint/rule-tester": "^8.24.1",
|
|
56
|
+
"@typescript-eslint/type-utils": "^8.24.1",
|
|
57
|
+
"@typescript-eslint/utils": "^8.24.1",
|
|
58
|
+
"azure-devops-node-api": "^14.1.0",
|
|
59
|
+
"c8": "^10.1.3",
|
|
60
|
+
"chai": "^4.5.0",
|
|
61
|
+
"chokidar": "^4.0.3",
|
|
62
|
+
"diff": "^7.0.0",
|
|
63
|
+
"dprint": "^0.49.0",
|
|
64
|
+
"esbuild": "^0.25.0",
|
|
65
|
+
"eslint": "^9.20.1",
|
|
66
|
+
"eslint-formatter-autolinkable-stylish": "^1.4.0",
|
|
67
|
+
"eslint-plugin-regexp": "^2.7.0",
|
|
68
|
+
"fast-xml-parser": "^4.5.2",
|
|
69
|
+
"glob": "^10.4.5",
|
|
70
|
+
"globals": "^15.15.0",
|
|
71
|
+
"hereby": "^1.10.0",
|
|
72
|
+
"jsonc-parser": "^3.3.1",
|
|
73
|
+
"knip": "^5.44.4",
|
|
74
|
+
"minimist": "^1.2.8",
|
|
75
|
+
"mocha": "^10.8.2",
|
|
76
|
+
"mocha-fivemat-progress-reporter": "^0.1.0",
|
|
77
|
+
"monocart-coverage-reports": "^2.12.1",
|
|
78
|
+
"ms": "^2.1.3",
|
|
79
|
+
"picocolors": "^1.1.1",
|
|
80
|
+
"playwright": "^1.50.1",
|
|
81
|
+
"source-map-support": "^0.5.21",
|
|
82
|
+
"tslib": "^2.8.1",
|
|
83
|
+
"typescript": "^5.7.3",
|
|
84
|
+
"typescript-eslint": "^8.24.1",
|
|
85
|
+
"which": "^3.0.1"
|
|
86
|
+
},
|
|
87
|
+
"overrides": {
|
|
88
|
+
"typescript@*": "$typescript"
|
|
89
|
+
},
|
|
90
|
+
"scripts": {
|
|
91
|
+
"test": "hereby runtests-parallel --light=false",
|
|
92
|
+
"test:eslint-rules": "hereby run-eslint-rules-tests",
|
|
93
|
+
"build": "npm run build:compiler && npm run build:tests",
|
|
94
|
+
"build:compiler": "hereby local",
|
|
95
|
+
"build:tests": "hereby tests",
|
|
96
|
+
"build:tests:notypecheck": "hereby tests --no-typecheck",
|
|
97
|
+
"clean": "hereby clean",
|
|
98
|
+
"gulp": "hereby",
|
|
99
|
+
"lint": "hereby lint",
|
|
100
|
+
"knip": "hereby knip",
|
|
101
|
+
"format": "dprint fmt",
|
|
102
|
+
"setup-hooks": "node scripts/link-hooks.mjs"
|
|
103
|
+
},
|
|
104
|
+
"browser": {
|
|
105
|
+
"fs": false,
|
|
106
|
+
"os": false,
|
|
107
|
+
"path": false,
|
|
108
|
+
"crypto": false,
|
|
109
|
+
"buffer": false,
|
|
110
|
+
"source-map-support": false,
|
|
111
|
+
"inspector": false,
|
|
112
|
+
"perf_hooks": false
|
|
113
|
+
},
|
|
114
|
+
"packageManager": "npm@8.19.4",
|
|
115
|
+
"volta": {
|
|
116
|
+
"node": "20.1.0",
|
|
117
|
+
"npm": "8.19.4"
|
|
118
|
+
},
|
|
119
|
+
"gitHead": "c63de15a992d37f0d6cec03ac7631872838602cb"
|
|
120
|
+
}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@linyjs/example-hello-world",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"lockfileVersion": 3,
|
|
5
|
+
"requires": true,
|
|
6
|
+
"packages": {
|
|
7
|
+
"": {
|
|
8
|
+
"name": "@linyjs/example-hello-world",
|
|
9
|
+
"version": "1.0.0",
|
|
10
|
+
"dependencies": {
|
|
11
|
+
"@linyjs/client-module-interface": "^0.0.1",
|
|
12
|
+
"@linyjs/server-module-interface": "^0.0.1",
|
|
13
|
+
"react": "^19.0.0"
|
|
14
|
+
},
|
|
15
|
+
"devDependencies": {
|
|
16
|
+
"@types/react": "^19.0.0",
|
|
17
|
+
"typescript": "^5.7.0"
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"node_modules/@linyjs/client-module-interface": {
|
|
21
|
+
"version": "0.0.1",
|
|
22
|
+
"resolved": "https://registry.npmmirror.com/@linyjs/client-module-interface/-/client-module-interface-0.0.1.tgz",
|
|
23
|
+
"integrity": "sha512-StKnCtzKq+ZHoApWQqOHEPrlMq0VqZ5C4ZYB9t27LNOzep8j4qwMqNnEP99S/KC4m/9rVGJlnJw0O+Kf2NVYYg==",
|
|
24
|
+
"peerDependencies": {
|
|
25
|
+
"react": "^19.0.0"
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
"node_modules/@linyjs/server-module-interface": {
|
|
29
|
+
"version": "0.0.1",
|
|
30
|
+
"resolved": "https://registry.npmmirror.com/@linyjs/server-module-interface/-/server-module-interface-0.0.1.tgz",
|
|
31
|
+
"integrity": "sha512-jrwW0uI8F7TCwGMvGVW4EkxcdDaXTIZhDS5tcahTiA9pqsNDMXULcy0oPrmaPMp6uaqdt3rSTp0ybThggym/RQ=="
|
|
32
|
+
},
|
|
33
|
+
"node_modules/@types/react": {
|
|
34
|
+
"version": "19.2.17",
|
|
35
|
+
"resolved": "https://registry.npmmirror.com/@types/react/-/react-19.2.17.tgz",
|
|
36
|
+
"integrity": "sha512-MXfmqaVPEVgkBT/aY0aGCkRWWtByiYQXo3xdQ8r5RzuFrPiRn8Gar2tQdXSUQ2GKV3bkXckek89V8wQBY2Q/Aw==",
|
|
37
|
+
"dev": true,
|
|
38
|
+
"license": "MIT",
|
|
39
|
+
"dependencies": {
|
|
40
|
+
"csstype": "^3.2.2"
|
|
41
|
+
}
|
|
42
|
+
},
|
|
43
|
+
"node_modules/csstype": {
|
|
44
|
+
"version": "3.2.3",
|
|
45
|
+
"resolved": "https://registry.npmmirror.com/csstype/-/csstype-3.2.3.tgz",
|
|
46
|
+
"integrity": "sha512-z1HGKcYy2xA8AGQfwrn0PAy+PB7X/GSj3UVJW9qKyn43xWa+gl5nXmU4qqLMRzWVLFC8KusUX8T/0kCiOYpAIQ==",
|
|
47
|
+
"dev": true,
|
|
48
|
+
"license": "MIT"
|
|
49
|
+
},
|
|
50
|
+
"node_modules/react": {
|
|
51
|
+
"version": "19.2.7",
|
|
52
|
+
"resolved": "https://registry.npmmirror.com/react/-/react-19.2.7.tgz",
|
|
53
|
+
"integrity": "sha512-HNe9WslTbXmFK8o8cmwgAeJFSBvt1bPdHCVKtaaV+WlAN36mpT4hcRpwbf3fY56ar2oIXzsBpOAiIRHAdY0OlQ==",
|
|
54
|
+
"license": "MIT",
|
|
55
|
+
"engines": {
|
|
56
|
+
"node": ">=0.10.0"
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
"node_modules/typescript": {
|
|
60
|
+
"version": "5.9.3",
|
|
61
|
+
"resolved": "https://registry.npmmirror.com/typescript/-/typescript-5.9.3.tgz",
|
|
62
|
+
"integrity": "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==",
|
|
63
|
+
"dev": true,
|
|
64
|
+
"license": "Apache-2.0",
|
|
65
|
+
"bin": {
|
|
66
|
+
"tsc": "bin/tsc",
|
|
67
|
+
"tsserver": "bin/tsserver"
|
|
68
|
+
},
|
|
69
|
+
"engines": {
|
|
70
|
+
"node": ">=14.17"
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@linyjs/example-hello-world",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "Hello World example plugin for linyjs framework",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"scripts": {
|
|
7
|
+
"build": "tsc",
|
|
8
|
+
"dev": "tsc --watch",
|
|
9
|
+
"pack": "npx @linyjs/cli pack"
|
|
10
|
+
},
|
|
11
|
+
"dependencies": {
|
|
12
|
+
"@linyjs/server-module-interface": "^0.0.1",
|
|
13
|
+
"@linyjs/client-module-interface": "^0.0.1",
|
|
14
|
+
"react": "^19.0.0"
|
|
15
|
+
},
|
|
16
|
+
"devDependencies": {
|
|
17
|
+
"typescript": "^5.7.0",
|
|
18
|
+
"@types/react": "^19.0.0"
|
|
19
|
+
},
|
|
20
|
+
"linyjs": {
|
|
21
|
+
"compatibleVersions": ">=0.0.1 <1.0.0"
|
|
22
|
+
}
|
|
23
|
+
}
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import type { IModule } from '@linyjs/client-module-interface';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* Hello World 页面组件
|
|
6
|
+
*/
|
|
7
|
+
function HelloPage() {
|
|
8
|
+
const [message, setMessage] = React.useState('Loading...');
|
|
9
|
+
const [name, setName] = React.useState('World');
|
|
10
|
+
|
|
11
|
+
// 调用 API 获取问候消息
|
|
12
|
+
React.useEffect(() => {
|
|
13
|
+
fetch(`/api/hello?name=${encodeURIComponent(name)}`)
|
|
14
|
+
.then(res => res.json())
|
|
15
|
+
.then(data => {
|
|
16
|
+
setMessage(data.message);
|
|
17
|
+
})
|
|
18
|
+
.catch(err => {
|
|
19
|
+
console.error('Failed to fetch:', err);
|
|
20
|
+
setMessage('Error loading message');
|
|
21
|
+
});
|
|
22
|
+
}, [name]);
|
|
23
|
+
|
|
24
|
+
return (
|
|
25
|
+
<div style={{
|
|
26
|
+
padding: '40px',
|
|
27
|
+
maxWidth: '600px',
|
|
28
|
+
margin: '0 auto',
|
|
29
|
+
fontFamily: 'Arial, sans-serif'
|
|
30
|
+
}}>
|
|
31
|
+
<h1 style={{ color: '#333' }}>👋 Hello World Plugin</h1>
|
|
32
|
+
|
|
33
|
+
<div style={{
|
|
34
|
+
marginTop: '20px',
|
|
35
|
+
padding: '20px',
|
|
36
|
+
backgroundColor: '#f5f5f5',
|
|
37
|
+
borderRadius: '8px'
|
|
38
|
+
}}>
|
|
39
|
+
<p style={{ fontSize: '18px', color: '#666' }}>{message}</p>
|
|
40
|
+
</div>
|
|
41
|
+
|
|
42
|
+
<div style={{ marginTop: '20px' }}>
|
|
43
|
+
<label style={{ display: 'block', marginBottom: '8px', color: '#666' }}>
|
|
44
|
+
Enter your name:
|
|
45
|
+
</label>
|
|
46
|
+
<input
|
|
47
|
+
type="text"
|
|
48
|
+
value={name}
|
|
49
|
+
onChange={(e) => setName(e.target.value)}
|
|
50
|
+
placeholder="Enter your name"
|
|
51
|
+
style={{
|
|
52
|
+
padding: '10px',
|
|
53
|
+
fontSize: '16px',
|
|
54
|
+
border: '1px solid #ddd',
|
|
55
|
+
borderRadius: '4px',
|
|
56
|
+
width: '100%',
|
|
57
|
+
boxSizing: 'border-box'
|
|
58
|
+
}}
|
|
59
|
+
/>
|
|
60
|
+
</div>
|
|
61
|
+
|
|
62
|
+
<div style={{
|
|
63
|
+
marginTop: '30px',
|
|
64
|
+
padding: '15px',
|
|
65
|
+
backgroundColor: '#e3f2fd',
|
|
66
|
+
borderRadius: '4px',
|
|
67
|
+
fontSize: '14px',
|
|
68
|
+
color: '#1976d2'
|
|
69
|
+
}}>
|
|
70
|
+
<strong>💡 Tip:</strong> This is a minimal linyjs plugin example.
|
|
71
|
+
Try modifying the code in <code>src/server/index.ts</code> and <code>src/client/index.tsx</code>.
|
|
72
|
+
</div>
|
|
73
|
+
</div>
|
|
74
|
+
);
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
/**
|
|
78
|
+
* 路由服务
|
|
79
|
+
*/
|
|
80
|
+
class HelloRouteService {
|
|
81
|
+
basePath = '/hello';
|
|
82
|
+
|
|
83
|
+
getRoutes() {
|
|
84
|
+
return [
|
|
85
|
+
{
|
|
86
|
+
path: '/',
|
|
87
|
+
component: HelloPage,
|
|
88
|
+
key: 'hello-page',
|
|
89
|
+
meta: {
|
|
90
|
+
title: 'Hello World',
|
|
91
|
+
requiresAuth: false
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
];
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
/**
|
|
99
|
+
* 客户端模块定义
|
|
100
|
+
*/
|
|
101
|
+
export const helloClientModule: IModule = {
|
|
102
|
+
name: 'helloClient',
|
|
103
|
+
serviceDefs: [
|
|
104
|
+
{
|
|
105
|
+
serviceTag: 'helloRoute',
|
|
106
|
+
serviceImpl: HelloRouteService,
|
|
107
|
+
meta: { usageType: 'route' }
|
|
108
|
+
}
|
|
109
|
+
]
|
|
110
|
+
};
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import type { IModule } from '@linyjs/server-module-interface';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Hello World 控制器
|
|
5
|
+
* 提供一个简单的 API 端点返回问候消息
|
|
6
|
+
*/
|
|
7
|
+
class HelloController {
|
|
8
|
+
getRoutes() {
|
|
9
|
+
return [
|
|
10
|
+
{
|
|
11
|
+
method: 'GET' as const,
|
|
12
|
+
path: '/api/hello',
|
|
13
|
+
middlewares: [],
|
|
14
|
+
responseType: 'json' as const,
|
|
15
|
+
handler: async (params: any, ctx: any) => {
|
|
16
|
+
// 获取查询参数(如果有)
|
|
17
|
+
const name = params.query?.name || 'World';
|
|
18
|
+
|
|
19
|
+
return {
|
|
20
|
+
message: `Hello, ${name}!`,
|
|
21
|
+
timestamp: new Date().toISOString(),
|
|
22
|
+
plugin: 'hello-world-example'
|
|
23
|
+
};
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
];
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* 服务端模块定义
|
|
32
|
+
*/
|
|
33
|
+
export const helloServerModule: IModule = {
|
|
34
|
+
name: 'helloServer',
|
|
35
|
+
serviceDefs: [
|
|
36
|
+
{
|
|
37
|
+
serviceTag: 'helloController',
|
|
38
|
+
serviceImpl: HelloController,
|
|
39
|
+
meta: { usageType: 'controller' }
|
|
40
|
+
}
|
|
41
|
+
]
|
|
42
|
+
};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
{
|
|
2
|
+
"compilerOptions": {
|
|
3
|
+
"target": "ES2020",
|
|
4
|
+
"module": "ESNext",
|
|
5
|
+
"lib": ["ES2020", "DOM"],
|
|
6
|
+
"jsx": "react-jsx",
|
|
7
|
+
"declaration": true,
|
|
8
|
+
"outDir": "./dist",
|
|
9
|
+
"rootDir": "./src",
|
|
10
|
+
"strict": true,
|
|
11
|
+
"esModuleInterop": true,
|
|
12
|
+
"skipLibCheck": true,
|
|
13
|
+
"moduleResolution": "node"
|
|
14
|
+
},
|
|
15
|
+
"include": ["src/**/*"]
|
|
16
|
+
}
|
package/package.json
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@linyjs/plugin-docs",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "Plugin development documentation and examples for linyjs framework",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"linyjs",
|
|
7
|
+
"plugin",
|
|
8
|
+
"documentation",
|
|
9
|
+
"examples",
|
|
10
|
+
"tutorial"
|
|
11
|
+
],
|
|
12
|
+
"author": "linyjs Team",
|
|
13
|
+
"license": "MIT",
|
|
14
|
+
"repository": {
|
|
15
|
+
"type": "git",
|
|
16
|
+
"url": "https://github.com/linyjs/linyjs.git",
|
|
17
|
+
"directory": "packages/plugin-docs"
|
|
18
|
+
},
|
|
19
|
+
"files": [
|
|
20
|
+
"docs",
|
|
21
|
+
"examples",
|
|
22
|
+
"src",
|
|
23
|
+
"README.md"
|
|
24
|
+
],
|
|
25
|
+
"bin": {
|
|
26
|
+
"plugin-docs": "src/cli.ts"
|
|
27
|
+
},
|
|
28
|
+
"main": "src/cli.ts",
|
|
29
|
+
"type": "module",
|
|
30
|
+
"peerDependencies": {
|
|
31
|
+
"@linyjs/server-module-interface": "0.0.3",
|
|
32
|
+
"@linyjs/client-module-interface": "0.0.3",
|
|
33
|
+
"@linyjs/ui-slots-interface": "0.0.3"
|
|
34
|
+
},
|
|
35
|
+
"dependencies": {
|
|
36
|
+
"commander": "^11.1.0"
|
|
37
|
+
},
|
|
38
|
+
"devDependencies": {
|
|
39
|
+
"typescript": "^5.7.0",
|
|
40
|
+
"@types/node": "^20.10.0"
|
|
41
|
+
}
|
|
42
|
+
}
|