0
Fork 0
mirror of https://github.com/logto-io/logto.git synced 2024-12-16 20:26:19 -05:00

Initial commit

This commit is contained in:
Gao Sun 2021-06-06 18:30:37 +08:00
parent c815a52b37
commit afcfd12d87
No known key found for this signature in database
GPG key ID: 0F0EFA2E36639F31
10 changed files with 4496 additions and 0 deletions

23
packages/core/.gitignore vendored Normal file
View file

@ -0,0 +1,23 @@
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
# dependencies
/node_modules
/.pnp
.pnp.js
# testing
/coverage
# production
/build
# misc
.DS_Store
.env.local
.env.development.local
.env.test.local
.env.production.local
npm-debug.log*
yarn-debug.log*
yarn-error.log*

View file

@ -0,0 +1,3 @@
{
"printWidth": 100
}

5
packages/core/.vscode/extensions.json vendored Normal file
View file

@ -0,0 +1,5 @@
{
"recommendations": [
"samverschueren.linter-xo"
]
}

4
packages/core/.vscode/settings.json vendored Normal file
View file

@ -0,0 +1,4 @@
{
"typescript.tsdk": "node_modules/typescript/lib",
"editor.defaultFormatter": "samverschueren.linter-xo"
}

View file

@ -0,0 +1,4 @@
{
"space": true,
"prettier": true
}

13
packages/core/README.md Normal file
View file

@ -0,0 +1,13 @@
# Logto Provider
The backend for Logto auth service.
## Get Started
```bash
yarn && yarn dev
```
## Notes
Upgrade `xo` after [this issue](https://github.com/SamVerschueren/vscode-linter-xo/issues/91) is solved.

View file

@ -0,0 +1,22 @@
{
"name": "@logto/provider",
"version": "1.0.0",
"description": "The backend for Logto auth service.",
"main": "index.js",
"author": "Logto",
"license": "MIT",
"scripts": {
"build": "tsc",
"lint": "xo src/",
"dev": "tsc-watch --onSuccess \"node ./build/index.js\""
},
"dependencies": {
"koa": "^2.13.1"
},
"devDependencies": {
"@types/koa": "^2.13.3",
"tsc-watch": "^4.4.0",
"typescript": "^4.3.2",
"xo": "0.39.1"
}
}

View file

@ -0,0 +1,13 @@
import Koa from 'koa';
const app = new Koa();
app.use((ctx) => {
ctx.body = 'Hello, world!';
});
const PORT = 3000;
app.listen(PORT, () => {
console.log(`App is listening on port ${PORT}`);
});

View file

@ -0,0 +1,16 @@
{
"compilerOptions": {
"target": "es2021",
"esModuleInterop": true,
"allowSyntheticDefaultImports": true,
"strict": true,
"forceConsistentCasingInFileNames": true,
"noFallthroughCasesInSwitch": true,
"module": "commonjs",
"moduleResolution": "node",
"outDir": "build"
},
"include": [
"src"
]
}

4393
packages/core/yarn.lock Normal file

File diff suppressed because it is too large Load diff