fastscript 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/.github/workflows/ci.yml +17 -0
- package/CHANGELOG.md +5 -0
- package/Dockerfile +9 -0
- package/LICENSE +21 -0
- package/README.md +102 -0
- package/app/api/auth.js +10 -0
- package/app/api/hello.js +3 -0
- package/app/api/upload.js +9 -0
- package/app/api/webhook.js +10 -0
- package/app/db/migrations/001_init.js +6 -0
- package/app/db/seed.js +5 -0
- package/app/env.schema.js +6 -0
- package/app/middleware.fs +7 -0
- package/app/pages/404.fs +3 -0
- package/app/pages/_layout.fs +17 -0
- package/app/pages/benchmarks.fs +15 -0
- package/app/pages/docs/index.fs +16 -0
- package/app/pages/index.fs +22 -0
- package/app/pages/private.fs +12 -0
- package/app/pages/showcase.fs +14 -0
- package/app/styles.css +14 -0
- package/docs/AI_CONTEXT_PACK_V1.md +25 -0
- package/docs/DEPLOY_GUIDE.md +14 -0
- package/docs/INCIDENT_PLAYBOOK.md +18 -0
- package/docs/INTEROP_RULES.md +7 -0
- package/docs/PLUGIN_API_CONTRACT.md +22 -0
- package/ecosystem.config.cjs +1 -0
- package/examples/fullstack/README.md +10 -0
- package/examples/fullstack/app/api/orders.js +8 -0
- package/examples/fullstack/app/db/migrations/001_init.js +3 -0
- package/examples/fullstack/app/db/seed.js +3 -0
- package/examples/fullstack/app/jobs/send-order-email.js +4 -0
- package/examples/fullstack/app/pages/_layout.fs +1 -0
- package/examples/fullstack/app/pages/index.fs +3 -0
- package/examples/startup-mvp/README.md +8 -0
- package/examples/startup-mvp/app/api/cart.js +9 -0
- package/examples/startup-mvp/app/api/checkout.js +8 -0
- package/examples/startup-mvp/app/db/migrations/001_products.js +6 -0
- package/examples/startup-mvp/app/jobs/send-receipt.js +4 -0
- package/examples/startup-mvp/app/pages/_layout.fs +3 -0
- package/examples/startup-mvp/app/pages/dashboard/index.fs +9 -0
- package/examples/startup-mvp/app/pages/index.fs +18 -0
- package/package.json +50 -0
- package/scripts/bench-report.mjs +36 -0
- package/scripts/release.mjs +21 -0
- package/scripts/smoke-dev.mjs +78 -0
- package/scripts/smoke-start.mjs +41 -0
- package/scripts/test-auth.mjs +26 -0
- package/scripts/test-db.mjs +31 -0
- package/scripts/test-jobs.mjs +15 -0
- package/scripts/test-middleware.mjs +37 -0
- package/scripts/test-roundtrip.mjs +44 -0
- package/scripts/test-validation.mjs +17 -0
- package/scripts/test-webhook-storage.mjs +22 -0
- package/spec/FASTSCRIPT_1000_BUILD_LIST.md +1090 -0
- package/src/auth-flows.mjs +29 -0
- package/src/auth.mjs +115 -0
- package/src/bench.mjs +46 -0
- package/src/build.mjs +222 -0
- package/src/cache.mjs +58 -0
- package/src/check.mjs +22 -0
- package/src/cli.mjs +71 -0
- package/src/compat.mjs +122 -0
- package/src/create.mjs +190 -0
- package/src/db-cli.mjs +45 -0
- package/src/db-postgres.mjs +40 -0
- package/src/db.mjs +103 -0
- package/src/deploy.mjs +65 -0
- package/src/dev.mjs +5 -0
- package/src/env.mjs +89 -0
- package/src/export.mjs +83 -0
- package/src/fs-normalize.mjs +100 -0
- package/src/interop.mjs +16 -0
- package/src/jobs.mjs +127 -0
- package/src/logger.mjs +27 -0
- package/src/middleware.mjs +14 -0
- package/src/migrate.mjs +81 -0
- package/src/observability.mjs +21 -0
- package/src/security.mjs +55 -0
- package/src/server-runtime.mjs +339 -0
- package/src/start.mjs +10 -0
- package/src/storage.mjs +56 -0
- package/src/validate.mjs +18 -0
- package/src/validation.mjs +79 -0
- package/src/webhook.mjs +71 -0
- package/src/worker.mjs +5 -0
- package/vercel.json +15 -0
- package/vscode/fastscript-language/README.md +12 -0
- package/vscode/fastscript-language/extension.js +24 -0
- package/vscode/fastscript-language/language-configuration.json +6 -0
- package/vscode/fastscript-language/lsp/server.cjs +27 -0
- package/vscode/fastscript-language/lsp/smoke-test.cjs +1 -0
- package/vscode/fastscript-language/package.json +36 -0
- package/vscode/fastscript-language/snippets/fastscript.code-snippets +24 -0
- package/vscode/fastscript-language/syntaxes/fastscript.tmLanguage.json +21 -0
- package/wrangler.toml +5 -0
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "fastscript-language",
|
|
3
|
+
"displayName": "FastScript Language",
|
|
4
|
+
"description": "Syntax and language support for FastScript (.fs)",
|
|
5
|
+
"version": "0.1.0",
|
|
6
|
+
"publisher": "lakesbim-velox",
|
|
7
|
+
"engines": { "vscode": "^1.90.0" },
|
|
8
|
+
"categories": ["Programming Languages"],
|
|
9
|
+
"activationEvents": ["onLanguage:fastscript"],
|
|
10
|
+
"main": "./extension.js",
|
|
11
|
+
"contributes": {
|
|
12
|
+
"languages": [{
|
|
13
|
+
"id": "fastscript",
|
|
14
|
+
"aliases": ["FastScript", "fastscript"],
|
|
15
|
+
"extensions": [".fs"],
|
|
16
|
+
"configuration": "./language-configuration.json"
|
|
17
|
+
}],
|
|
18
|
+
"grammars": [{
|
|
19
|
+
"language": "fastscript",
|
|
20
|
+
"scopeName": "source.fastscript",
|
|
21
|
+
"path": "./syntaxes/fastscript.tmLanguage.json"
|
|
22
|
+
}],
|
|
23
|
+
"snippets": [{
|
|
24
|
+
"language": "fastscript",
|
|
25
|
+
"path": "./snippets/fastscript.code-snippets"
|
|
26
|
+
}]
|
|
27
|
+
},
|
|
28
|
+
"scripts": {
|
|
29
|
+
"test:lsp": "node ./lsp/smoke-test.cjs"
|
|
30
|
+
},
|
|
31
|
+
"devDependencies": {
|
|
32
|
+
"vscode-languageclient": "^9.0.1",
|
|
33
|
+
"vscode-languageserver": "^9.0.1",
|
|
34
|
+
"vscode-languageserver-textdocument": "^1.0.11"
|
|
35
|
+
}
|
|
36
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
{
|
|
2
|
+
"FastScript Component": {
|
|
3
|
+
"prefix": "fcomp",
|
|
4
|
+
"body": [
|
|
5
|
+
"export default function ${1:Component}(${2:ctx}) {",
|
|
6
|
+
" return `",
|
|
7
|
+
" <section>${3}</section>",
|
|
8
|
+
" `;",
|
|
9
|
+
"}"
|
|
10
|
+
],
|
|
11
|
+
"description": "FastScript component"
|
|
12
|
+
},
|
|
13
|
+
"FastScript API": {
|
|
14
|
+
"prefix": "fapi",
|
|
15
|
+
"body": [
|
|
16
|
+
"export const schemas = { POST: { ${1:name}: \"string\" } };",
|
|
17
|
+
"export async function POST(ctx) {",
|
|
18
|
+
" const body = await ctx.input.validateBody(schemas.POST);",
|
|
19
|
+
" return ctx.helpers.json({ ok: true, body });",
|
|
20
|
+
"}"
|
|
21
|
+
],
|
|
22
|
+
"description": "FastScript API route"
|
|
23
|
+
}
|
|
24
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://raw.githubusercontent.com/martinring/tmlanguage/master/tmlanguage.json",
|
|
3
|
+
"name": "FastScript",
|
|
4
|
+
"scopeName": "source.fastscript",
|
|
5
|
+
"patterns": [
|
|
6
|
+
{ "include": "#comments" },
|
|
7
|
+
{ "include": "#strings" },
|
|
8
|
+
{ "include": "#keywords" },
|
|
9
|
+
{ "include": "#numbers" },
|
|
10
|
+
{ "include": "#operators" },
|
|
11
|
+
{ "include": "#functions" }
|
|
12
|
+
],
|
|
13
|
+
"repository": {
|
|
14
|
+
"comments": { "patterns": [{ "name": "comment.line.double-slash.fastscript", "match": "//.*$" }] },
|
|
15
|
+
"strings": { "patterns": [{ "name": "string.quoted.double.fastscript", "begin": "\"", "end": "\"", "patterns": [{ "match": "\\\\.", "name": "constant.character.escape.fastscript" }] }] },
|
|
16
|
+
"keywords": { "patterns": [{ "name": "keyword.control.fastscript", "match": "\\b(export|default|function|return|if|else|for|while|async|await|import|from|state|fn)\\b" }, { "name": "keyword.other.reactive.fastscript", "match": "~[A-Za-z_$][\\w$]*" }] },
|
|
17
|
+
"numbers": { "patterns": [{ "name": "constant.numeric.fastscript", "match": "\\b\\d+(?:\\.\\d+)?\\b" }] },
|
|
18
|
+
"operators": { "patterns": [{ "name": "keyword.operator.fastscript", "match": "[+\\-*/%=!<>|&]+" }] },
|
|
19
|
+
"functions": { "patterns": [{ "name": "entity.name.function.fastscript", "match": "\\b([A-Za-z_$][\\w$]*)\\s*(?=\\()" }] }
|
|
20
|
+
}
|
|
21
|
+
}
|