create-packer 1.43.12 → 1.43.14
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/package.json +1 -1
- package/template/lib/workspace/package.json +2 -1
- package/template/lib/workspace/packages/ts/package.json +2 -2
- package/template/web-app/react-rsbuild/domain/app/components/app-context.tsx +21 -3
- package/template/web-app/react-rsbuild/domain/app/components/app.tsx +5 -3
- package/template/web-app/react-rsbuild/domain/app/startApp.tsx +6 -6
- package/template/web-app/react-rsbuild/domain/router/router.tsx +0 -1
- package/template/web-app/react-rsbuild/env.d.ts +6 -2
- package/template/web-app/react-rsbuild/main.tsx +3 -3
- package/template/web-app/react-rsbuild/package.json +4 -2
- package/template/web-app/react-rsbuild/pages/home/view.styled.ts +4 -6
- package/template/web-app/react-rsbuild/pages/home/view.tsx +10 -11
- package/template/web-app/react-rsbuild/postcss.config.cjs +7 -7
- package/template/web-app/react-rsbuild/rsbuild.config.ts +14 -9
- package/template/web-app/react-rsbuild/shared/service/home.ts +6 -4
- package/template/web-app/react-rsbuild/shared/styles/global-style.tsx +14 -0
- package/template/web-app/react-rsbuild/shared/styles/index.ts +2 -0
- package/template/web-app/react-rsbuild/tsconfig.node.json +1 -1
- package/template/web-app/react-vite/domain/app/components/app-context.tsx +21 -3
- package/template/web-app/react-vite/domain/app/components/app.tsx +5 -3
- package/template/web-app/react-vite/domain/router/router.tsx +0 -1
- package/template/web-app/react-vite/package.json +4 -1
- package/template/web-app/react-vite/pages/home/view.styled.ts +4 -6
- package/template/web-app/react-vite/pages/home/view.tsx +3 -4
- package/template/web-app/react-vite/shared/service/home.ts +6 -4
- package/template/web-app/react-vite/shared/styles/global-style.tsx +14 -0
- package/template/web-app/react-vite/shared/styles/index.ts +2 -0
- package/template/web-app/{react-rsbuild/shared/theme → react-vite/shared/styles}/theme.styled.ts +0 -1
- package/template/web-app/react-vite/vite-env.d.ts +5 -4
- package/template/web-app/react-vite/vite.config.ts +78 -78
- package/template/web-app/vue/domain/app/components/app.vue +1 -1
- package/template/web-app/vue/main.ts +1 -1
- package/template/web-app/vue/package.json +2 -2
- package/template/web-app/vue/vite.config.ts +4 -4
- package/template/web-app/vue-rsbuild/domain/app/components/app.vue +1 -1
- package/template/web-app/vue-rsbuild/main.ts +1 -1
- package/template/web-app/vue-rsbuild/package.json +2 -2
- package/template/web-app/vue-rsbuild/tsconfig.node.json +2 -2
- package/template/web-extension/.wxt/eslint-auto-imports.mjs +29 -1
- package/template/web-extension/.wxt/types/imports-module.d.ts +20 -0
- package/template/web-extension/.wxt/types/imports.d.ts +45 -17
- package/template/web-extension/.wxt/types/paths.d.ts +1 -0
- package/template/web-extension/.wxt/wxt.d.ts +1 -1
- package/template/web-extension/entrypoints/content/constants/base.ts +1 -1
- package/template/web-extension/entrypoints/content/constants/index.ts +1 -1
- package/template/web-extension/entrypoints/content/domain/app/tools/insertApp.tsx +58 -58
- package/template/web-extension/entrypoints/content/index.tsx +1 -1
- package/template/web-extension/entrypoints/content/modules/common/common.tsx +10 -10
- package/template/web-extension/entrypoints/popup/main.tsx +2 -2
- package/template/web-extension/package.json +4 -2
- package/template/web-extension/shared/components/app-context/index.ts +1 -0
- package/template/web-extension/shared/components/{app-context.tsx → app-context/view.tsx} +4 -2
- package/template/web-extension/shared/components/index.ts +1 -1
- package/template/web-extension/shared/styles/global-style.tsx +14 -0
- package/template/web-extension/shared/styles/index.ts +2 -2
- package/template/web-extension/vite-env.d.ts +3 -3
- package/template/web-extension/wxt.config.ts +10 -4
- package/template/nest/.eslintrc.js +0 -25
- package/template/nest/.gitignore +0 -35
- package/template/nest/.husky/pre-commit +0 -4
- package/template/nest/.prettierrc +0 -6
- package/template/nest/README.md +0 -73
- package/template/nest/nest-cli.json +0 -5
- package/template/nest/package.json +0 -82
- package/template/nest/src/app.controller.spec.ts +0 -22
- package/template/nest/src/app.controller.ts +0 -12
- package/template/nest/src/app.module.ts +0 -10
- package/template/nest/src/app.service.ts +0 -8
- package/template/nest/src/main.ts +0 -10
- package/template/nest/src/utils/transform.interceptor.ts +0 -26
- package/template/nest/test/app.e2e-spec.ts +0 -24
- package/template/nest/test/jest-e2e.json +0 -9
- package/template/nest/tsconfig.build.json +0 -5
- package/template/nest/tsconfig.json +0 -21
- package/template/web-app/next/.editorconfig +0 -14
- package/template/web-app/next/.eslintrc.json +0 -8
- package/template/web-app/next/.gitignore +0 -36
- package/template/web-app/next/.husky/commit-msg +0 -4
- package/template/web-app/next/.husky/pre-commit +0 -4
- package/template/web-app/next/.prettierrc +0 -12
- package/template/web-app/next/.stylelintrc +0 -29
- package/template/web-app/next/.vscode/extensions.json +0 -7
- package/template/web-app/next/README.md +0 -34
- package/template/web-app/next/app/favicon.ico +0 -0
- package/template/web-app/next/app/globals.css +0 -22
- package/template/web-app/next/app/layout.tsx +0 -18
- package/template/web-app/next/app/page.tsx +0 -113
- package/template/web-app/next/commitlint.config.cjs +0 -1
- package/template/web-app/next/next-env.d.ts +0 -5
- package/template/web-app/next/next.config.js +0 -5
- package/template/web-app/next/package.json +0 -47
- package/template/web-app/next/postcss.config.js +0 -6
- package/template/web-app/next/public/next.svg +0 -1
- package/template/web-app/next/public/vercel.svg +0 -1
- package/template/web-app/next/tailwind.config.js +0 -20
- package/template/web-app/next/tsconfig.json +0 -21
- package/template/web-app/react-rsbuild/domain/app/app.styled.ts +0 -3
- package/template/web-app/react-rsbuild/shared/theme/index.ts +0 -1
- package/template/web-app/react-vite/domain/app/app.styled.ts +0 -3
- package/template/web-app/react-vite/shared/theme/index.ts +0 -1
- package/template/web-app/vue/tailwind.config.cjs +0 -15
- package/template/web-app/vue-rsbuild/tailwind.config.cjs +0 -15
- package/template/web-extension/shared/styles/global.styled.ts +0 -9
- /package/template/web-app/{react-vite/shared/theme → react-rsbuild/shared/styles}/theme.styled.ts +0 -0
- /package/template/web-app/vue/{router → domain/router}/home/index.ts +0 -0
- /package/template/web-app/vue/{router → domain/router}/home/names.ts +0 -0
- /package/template/web-app/vue/{router → domain/router}/home/routes.ts +0 -0
- /package/template/web-app/vue/{router → domain/router}/index.ts +0 -0
- /package/template/web-app/vue/{router → domain/router}/names.ts +0 -0
- /package/template/web-app/vue-rsbuild/{router → domain/router}/home/index.ts +0 -0
- /package/template/web-app/vue-rsbuild/{router → domain/router}/home/names.ts +0 -0
- /package/template/web-app/vue-rsbuild/{router → domain/router}/home/routes.ts +0 -0
- /package/template/web-app/vue-rsbuild/{router → domain/router}/index.ts +0 -0
- /package/template/web-app/vue-rsbuild/{router → domain/router}/names.ts +0 -0
|
@@ -1,14 +1,16 @@
|
|
|
1
1
|
import { FunctionComponent, ReactNode } from 'react'
|
|
2
|
-
import { ThemeProvider } from '
|
|
2
|
+
import { ThemeProvider } from '@emotion/react'
|
|
3
3
|
import { QueryClient, QueryClientProvider } from '@tanstack/react-query'
|
|
4
4
|
import { theme } from '@/shared/styles'
|
|
5
5
|
|
|
6
6
|
const queryClient = new QueryClient()
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
const AppContext: FunctionComponent<{ children: ReactNode }> = props => {
|
|
9
9
|
return (
|
|
10
10
|
<QueryClientProvider client={queryClient}>
|
|
11
11
|
<ThemeProvider theme={theme}>{props.children}</ThemeProvider>
|
|
12
12
|
</QueryClientProvider>
|
|
13
13
|
)
|
|
14
14
|
}
|
|
15
|
+
|
|
16
|
+
export default AppContext
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from './app-context'
|
|
1
|
+
export * as AppContext from './app-context'
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { FunctionComponent } from 'react'
|
|
2
|
+
import { css, Global } from '@emotion/react'
|
|
3
|
+
|
|
4
|
+
export const GlobalStyle: FunctionComponent<{ nameSpace?: string }> = props => {
|
|
5
|
+
return (
|
|
6
|
+
<Global
|
|
7
|
+
styles={css`
|
|
8
|
+
${props.nameSpace ? '.' + props.nameSpace : 'body'} {
|
|
9
|
+
margin: 0;
|
|
10
|
+
}
|
|
11
|
+
`}
|
|
12
|
+
/>
|
|
13
|
+
)
|
|
14
|
+
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export * from './theme.styled'
|
|
2
|
-
export * from './global
|
|
1
|
+
export * from './theme.styled'
|
|
2
|
+
export * from './global-style'
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="vite/client" />
|
|
2
2
|
/// <reference types="./.wxt/wxt.d.ts" />
|
|
3
3
|
|
|
4
|
-
import '
|
|
4
|
+
import '@emotion/react'
|
|
5
5
|
import { themeType } from './shared/styles'
|
|
6
6
|
|
|
7
7
|
declare global {
|
|
@@ -16,6 +16,6 @@ declare global {
|
|
|
16
16
|
}
|
|
17
17
|
}
|
|
18
18
|
|
|
19
|
-
declare module '
|
|
20
|
-
export interface
|
|
19
|
+
declare module '@emotion/react' {
|
|
20
|
+
export interface Theme extends themeType {}
|
|
21
21
|
}
|
|
@@ -13,8 +13,8 @@ const manifest: UserManifestFn = () => {
|
|
|
13
13
|
version: pkgJson.version,
|
|
14
14
|
host_permissions,
|
|
15
15
|
icons: {
|
|
16
|
-
'48': 'vite.
|
|
17
|
-
'128': 'vite.
|
|
16
|
+
'48': 'vite.svg',
|
|
17
|
+
'128': 'vite.svg'
|
|
18
18
|
}
|
|
19
19
|
}
|
|
20
20
|
}
|
|
@@ -27,10 +27,16 @@ export default defineConfig({
|
|
|
27
27
|
},
|
|
28
28
|
manifest,
|
|
29
29
|
runner: { disabled: true },
|
|
30
|
-
extensionApi: 'chrome',
|
|
31
30
|
imports: { eslintrc: { enabled: 9 } },
|
|
32
31
|
vite: ({ mode }) => ({
|
|
33
|
-
plugins: [
|
|
32
|
+
plugins: [
|
|
33
|
+
svgr(),
|
|
34
|
+
react({
|
|
35
|
+
babel: {
|
|
36
|
+
plugins: ['@emotion']
|
|
37
|
+
}
|
|
38
|
+
})
|
|
39
|
+
] as any,
|
|
34
40
|
resolve: {
|
|
35
41
|
alias: {
|
|
36
42
|
'@': __dirname
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
module.exports = {
|
|
2
|
-
parser: '@typescript-eslint/parser',
|
|
3
|
-
parserOptions: {
|
|
4
|
-
project: 'tsconfig.json',
|
|
5
|
-
tsconfigRootDir: __dirname,
|
|
6
|
-
sourceType: 'module',
|
|
7
|
-
},
|
|
8
|
-
plugins: ['@typescript-eslint/eslint-plugin'],
|
|
9
|
-
extends: [
|
|
10
|
-
'plugin:@typescript-eslint/recommended',
|
|
11
|
-
'plugin:prettier/recommended',
|
|
12
|
-
],
|
|
13
|
-
root: true,
|
|
14
|
-
env: {
|
|
15
|
-
node: true,
|
|
16
|
-
jest: true,
|
|
17
|
-
},
|
|
18
|
-
ignorePatterns: ['.eslintrc.js'],
|
|
19
|
-
rules: {
|
|
20
|
-
'@typescript-eslint/interface-name-prefix': 'off',
|
|
21
|
-
'@typescript-eslint/explicit-function-return-type': 'off',
|
|
22
|
-
'@typescript-eslint/explicit-module-boundary-types': 'off',
|
|
23
|
-
'@typescript-eslint/no-explicit-any': 'off',
|
|
24
|
-
},
|
|
25
|
-
}
|
package/template/nest/.gitignore
DELETED
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
# compiled output
|
|
2
|
-
/dist
|
|
3
|
-
/node_modules
|
|
4
|
-
|
|
5
|
-
# Logs
|
|
6
|
-
logs
|
|
7
|
-
*.log
|
|
8
|
-
npm-debug.log*
|
|
9
|
-
pnpm-debug.log*
|
|
10
|
-
yarn-debug.log*
|
|
11
|
-
yarn-error.log*
|
|
12
|
-
lerna-debug.log*
|
|
13
|
-
|
|
14
|
-
# OS
|
|
15
|
-
.DS_Store
|
|
16
|
-
|
|
17
|
-
# Tests
|
|
18
|
-
/coverage
|
|
19
|
-
/.nyc_output
|
|
20
|
-
|
|
21
|
-
# IDEs and editors
|
|
22
|
-
/.idea
|
|
23
|
-
.project
|
|
24
|
-
.classpath
|
|
25
|
-
.c9/
|
|
26
|
-
*.launch
|
|
27
|
-
.settings/
|
|
28
|
-
*.sublime-workspace
|
|
29
|
-
|
|
30
|
-
# IDE - VSCode
|
|
31
|
-
.vscode/*
|
|
32
|
-
!.vscode/settings.json
|
|
33
|
-
!.vscode/tasks.json
|
|
34
|
-
!.vscode/launch.json
|
|
35
|
-
!.vscode/extensions.json
|
package/template/nest/README.md
DELETED
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
<p align="center">
|
|
2
|
-
<a href="http://nestjs.com/" target="blank"><img src="https://nestjs.com/img/logo-small.svg" width="200" alt="Nest Logo" /></a>
|
|
3
|
-
</p>
|
|
4
|
-
|
|
5
|
-
[circleci-image]: https://img.shields.io/circleci/build/github/nestjs/nest/master?token=abc123def456
|
|
6
|
-
[circleci-url]: https://circleci.com/gh/nestjs/nest
|
|
7
|
-
|
|
8
|
-
<p align="center">A progressive <a href="http://nodejs.org" target="_blank">Node.js</a> framework for building efficient and scalable server-side applications.</p>
|
|
9
|
-
<p align="center">
|
|
10
|
-
<a href="https://www.npmjs.com/~nestjscore" target="_blank"><img src="https://img.shields.io/npm/v/@nestjs/core.svg" alt="NPM Version" /></a>
|
|
11
|
-
<a href="https://www.npmjs.com/~nestjscore" target="_blank"><img src="https://img.shields.io/npm/l/@nestjs/core.svg" alt="Package License" /></a>
|
|
12
|
-
<a href="https://www.npmjs.com/~nestjscore" target="_blank"><img src="https://img.shields.io/npm/dm/@nestjs/common.svg" alt="NPM Downloads" /></a>
|
|
13
|
-
<a href="https://circleci.com/gh/nestjs/nest" target="_blank"><img src="https://img.shields.io/circleci/build/github/nestjs/nest/master" alt="CircleCI" /></a>
|
|
14
|
-
<a href="https://coveralls.io/github/nestjs/nest?branch=master" target="_blank"><img src="https://coveralls.io/repos/github/nestjs/nest/badge.svg?branch=master#9" alt="Coverage" /></a>
|
|
15
|
-
<a href="https://discord.gg/G7Qnnhy" target="_blank"><img src="https://img.shields.io/badge/discord-online-brightgreen.svg" alt="Discord"/></a>
|
|
16
|
-
<a href="https://opencollective.com/nest#backer" target="_blank"><img src="https://opencollective.com/nest/backers/badge.svg" alt="Backers on Open Collective" /></a>
|
|
17
|
-
<a href="https://opencollective.com/nest#sponsor" target="_blank"><img src="https://opencollective.com/nest/sponsors/badge.svg" alt="Sponsors on Open Collective" /></a>
|
|
18
|
-
<a href="https://paypal.me/kamilmysliwiec" target="_blank"><img src="https://img.shields.io/badge/Donate-PayPal-ff3f59.svg"/></a>
|
|
19
|
-
<a href="https://opencollective.com/nest#sponsor" target="_blank"><img src="https://img.shields.io/badge/Support%20us-Open%20Collective-41B883.svg" alt="Support us"></a>
|
|
20
|
-
<a href="https://twitter.com/nestframework" target="_blank"><img src="https://img.shields.io/twitter/follow/nestframework.svg?style=social&label=Follow"></a>
|
|
21
|
-
</p>
|
|
22
|
-
<!--[](https://opencollective.com/nest#backer)
|
|
23
|
-
[](https://opencollective.com/nest#sponsor)-->
|
|
24
|
-
|
|
25
|
-
## Description
|
|
26
|
-
|
|
27
|
-
[Nest](https://github.com/nestjs/nest) framework TypeScript starter repository.
|
|
28
|
-
|
|
29
|
-
## Installation
|
|
30
|
-
|
|
31
|
-
```bash
|
|
32
|
-
$ npm install
|
|
33
|
-
```
|
|
34
|
-
|
|
35
|
-
## Running the app
|
|
36
|
-
|
|
37
|
-
```bash
|
|
38
|
-
# development
|
|
39
|
-
$ npm run start
|
|
40
|
-
|
|
41
|
-
# watch mode
|
|
42
|
-
$ npm run start:dev
|
|
43
|
-
|
|
44
|
-
# production mode
|
|
45
|
-
$ npm run start:prod
|
|
46
|
-
```
|
|
47
|
-
|
|
48
|
-
## Test
|
|
49
|
-
|
|
50
|
-
```bash
|
|
51
|
-
# unit tests
|
|
52
|
-
$ npm run test
|
|
53
|
-
|
|
54
|
-
# e2e tests
|
|
55
|
-
$ npm run test:e2e
|
|
56
|
-
|
|
57
|
-
# test coverage
|
|
58
|
-
$ npm run test:cov
|
|
59
|
-
```
|
|
60
|
-
|
|
61
|
-
## Support
|
|
62
|
-
|
|
63
|
-
Nest is an MIT-licensed open source project. It can grow thanks to the sponsors and support by the amazing backers. If you'd like to join them, please [read more here](https://docs.nestjs.com/support).
|
|
64
|
-
|
|
65
|
-
## Stay in touch
|
|
66
|
-
|
|
67
|
-
- Author - [Kamil Myśliwiec](https://kamilmysliwiec.com)
|
|
68
|
-
- Website - [https://nestjs.com](https://nestjs.com/)
|
|
69
|
-
- Twitter - [@nestframework](https://twitter.com/nestframework)
|
|
70
|
-
|
|
71
|
-
## License
|
|
72
|
-
|
|
73
|
-
Nest is [MIT licensed](LICENSE).
|
|
@@ -1,82 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "nest-temp",
|
|
3
|
-
"version": "0.0.1",
|
|
4
|
-
"description": "",
|
|
5
|
-
"author": "",
|
|
6
|
-
"private": true,
|
|
7
|
-
"license": "UNLICENSED",
|
|
8
|
-
"scripts": {
|
|
9
|
-
"prepare": "husky install",
|
|
10
|
-
"prebuild": "rimraf dist",
|
|
11
|
-
"build": "nest build",
|
|
12
|
-
"format": "prettier --write \"src/**/*.ts\" \"test/**/*.ts\"",
|
|
13
|
-
"start": "nest start",
|
|
14
|
-
"start:dev": "nest start --watch",
|
|
15
|
-
"start:debug": "nest start --debug --watch",
|
|
16
|
-
"start:prod": "node dist/main",
|
|
17
|
-
"lint": "eslint \"{src,apps,libs,test}/**/*.ts\"",
|
|
18
|
-
"lint:fix": "eslint \"{src,apps,libs,test}/**/*.ts\" --fix",
|
|
19
|
-
"test": "jest",
|
|
20
|
-
"test:watch": "jest --watch",
|
|
21
|
-
"test:cov": "jest --coverage",
|
|
22
|
-
"test:debug": "node --inspect-brk -r tsconfig-paths/register -r ts-node/register node_modules/.bin/jest --runInBand",
|
|
23
|
-
"test:e2e": "jest --config test/jest-e2e.json",
|
|
24
|
-
"cz": "cz",
|
|
25
|
-
"push": "npm run commit && git push",
|
|
26
|
-
"commit": "git add . && npm run cz"
|
|
27
|
-
},
|
|
28
|
-
"dependencies": {
|
|
29
|
-
"@nestjs/common": "9.3.8",
|
|
30
|
-
"@nestjs/core": "9.3.8",
|
|
31
|
-
"@nestjs/platform-express": "9.3.8",
|
|
32
|
-
"reflect-metadata": "0.1.13",
|
|
33
|
-
"rimraf": "4.1.2",
|
|
34
|
-
"rxjs": "7.8.0"
|
|
35
|
-
},
|
|
36
|
-
"devDependencies": {
|
|
37
|
-
"@nestjs/cli": "9.2.0",
|
|
38
|
-
"@nestjs/schematics": "9.0.4",
|
|
39
|
-
"@nestjs/testing": "9.3.8",
|
|
40
|
-
"@types/express": "4.17.17",
|
|
41
|
-
"@types/jest": "29.4.0",
|
|
42
|
-
"@types/node": "18.13.0",
|
|
43
|
-
"@types/supertest": "2.0.12",
|
|
44
|
-
"commitizen": "4.3.0",
|
|
45
|
-
"cz-adapter-eslint": "0.3.0",
|
|
46
|
-
"eslint": "9.17.0",
|
|
47
|
-
"eslint-config-prettier": "9.1.0",
|
|
48
|
-
"eslint-plugin-prettier": "5.2.1",
|
|
49
|
-
"husky": "9.1.6",
|
|
50
|
-
"jest": "29.4.2",
|
|
51
|
-
"prettier": "3.2.5",
|
|
52
|
-
"source-map-support": "0.5.21",
|
|
53
|
-
"supertest": "6.3.3",
|
|
54
|
-
"ts-jest": "29.0.5",
|
|
55
|
-
"ts-loader": "9.4.2",
|
|
56
|
-
"ts-node": "10.9.1",
|
|
57
|
-
"tsconfig-paths": "4.1.2",
|
|
58
|
-
"typescript": "5.8.2"
|
|
59
|
-
},
|
|
60
|
-
"jest": {
|
|
61
|
-
"moduleFileExtensions": [
|
|
62
|
-
"js",
|
|
63
|
-
"json",
|
|
64
|
-
"ts"
|
|
65
|
-
],
|
|
66
|
-
"rootDir": "src",
|
|
67
|
-
"testRegex": ".*\\.spec\\.ts$",
|
|
68
|
-
"transform": {
|
|
69
|
-
"^.+\\.(t|j)s$": "ts-jest"
|
|
70
|
-
},
|
|
71
|
-
"collectCoverageFrom": [
|
|
72
|
-
"**/*.(t|j)s"
|
|
73
|
-
],
|
|
74
|
-
"coverageDirectory": "../coverage",
|
|
75
|
-
"testEnvironment": "node"
|
|
76
|
-
},
|
|
77
|
-
"config": {
|
|
78
|
-
"commitizen": {
|
|
79
|
-
"path": "./node_modules/cz-adapter-eslint"
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
|
-
}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import { Test, TestingModule } from '@nestjs/testing'
|
|
2
|
-
import { AppController } from './app.controller'
|
|
3
|
-
import { AppService } from './app.service'
|
|
4
|
-
|
|
5
|
-
describe('AppController', () => {
|
|
6
|
-
let appController: AppController
|
|
7
|
-
|
|
8
|
-
beforeEach(async () => {
|
|
9
|
-
const app: TestingModule = await Test.createTestingModule({
|
|
10
|
-
controllers: [AppController],
|
|
11
|
-
providers: [AppService],
|
|
12
|
-
}).compile()
|
|
13
|
-
|
|
14
|
-
appController = app.get<AppController>(AppController)
|
|
15
|
-
})
|
|
16
|
-
|
|
17
|
-
describe('root', () => {
|
|
18
|
-
it('should return "Hello World!"', () => {
|
|
19
|
-
expect(appController.getHello()).toBe('Hello World!')
|
|
20
|
-
})
|
|
21
|
-
})
|
|
22
|
-
})
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { Controller, Get } from '@nestjs/common'
|
|
2
|
-
import { AppService } from './app.service'
|
|
3
|
-
|
|
4
|
-
@Controller()
|
|
5
|
-
export class AppController {
|
|
6
|
-
constructor(private readonly appService: AppService) {}
|
|
7
|
-
|
|
8
|
-
@Get()
|
|
9
|
-
getHello(): string {
|
|
10
|
-
return this.appService.getHello()
|
|
11
|
-
}
|
|
12
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import { NestFactory } from '@nestjs/core'
|
|
2
|
-
import { AppModule } from './app.module'
|
|
3
|
-
import { TransformInterceptor } from 'src/utils/transform.interceptor'
|
|
4
|
-
|
|
5
|
-
async function bootstrap() {
|
|
6
|
-
const app = await NestFactory.create(AppModule)
|
|
7
|
-
app.useGlobalInterceptors(new TransformInterceptor())
|
|
8
|
-
await app.listen(3000)
|
|
9
|
-
}
|
|
10
|
-
bootstrap()
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
Injectable,
|
|
3
|
-
NestInterceptor,
|
|
4
|
-
ExecutionContext,
|
|
5
|
-
CallHandler,
|
|
6
|
-
} from '@nestjs/common'
|
|
7
|
-
import { Observable } from 'rxjs'
|
|
8
|
-
import { map } from 'rxjs/operators'
|
|
9
|
-
|
|
10
|
-
export interface Response<T> {
|
|
11
|
-
data: T
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
@Injectable()
|
|
15
|
-
export class TransformInterceptor<T>
|
|
16
|
-
implements NestInterceptor<T, Response<T>>
|
|
17
|
-
{
|
|
18
|
-
intercept(
|
|
19
|
-
context: ExecutionContext,
|
|
20
|
-
next: CallHandler,
|
|
21
|
-
): Observable<Response<T>> {
|
|
22
|
-
return next
|
|
23
|
-
.handle()
|
|
24
|
-
.pipe(map((data) => ({ code: 200, message: '', data })))
|
|
25
|
-
}
|
|
26
|
-
}
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { Test, TestingModule } from '@nestjs/testing'
|
|
2
|
-
import { INestApplication } from '@nestjs/common'
|
|
3
|
-
import * as request from 'supertest'
|
|
4
|
-
import { AppModule } from '../src/app.module'
|
|
5
|
-
|
|
6
|
-
describe('AppController (e2e)', () => {
|
|
7
|
-
let app: INestApplication
|
|
8
|
-
|
|
9
|
-
beforeEach(async () => {
|
|
10
|
-
const moduleFixture: TestingModule = await Test.createTestingModule({
|
|
11
|
-
imports: [AppModule],
|
|
12
|
-
}).compile()
|
|
13
|
-
|
|
14
|
-
app = moduleFixture.createNestApplication()
|
|
15
|
-
await app.init()
|
|
16
|
-
})
|
|
17
|
-
|
|
18
|
-
it('/ (GET)', () => {
|
|
19
|
-
return request(app.getHttpServer())
|
|
20
|
-
.get('/')
|
|
21
|
-
.expect(200)
|
|
22
|
-
.expect('Hello World!')
|
|
23
|
-
})
|
|
24
|
-
})
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"compilerOptions": {
|
|
3
|
-
"module": "commonjs",
|
|
4
|
-
"declaration": true,
|
|
5
|
-
"removeComments": true,
|
|
6
|
-
"emitDecoratorMetadata": true,
|
|
7
|
-
"experimentalDecorators": true,
|
|
8
|
-
"allowSyntheticDefaultImports": true,
|
|
9
|
-
"target": "es2017",
|
|
10
|
-
"sourceMap": true,
|
|
11
|
-
"outDir": "./dist",
|
|
12
|
-
"baseUrl": "./",
|
|
13
|
-
"incremental": true,
|
|
14
|
-
"skipLibCheck": true,
|
|
15
|
-
"strictNullChecks": false,
|
|
16
|
-
"noImplicitAny": false,
|
|
17
|
-
"strictBindCallApply": false,
|
|
18
|
-
"forceConsistentCasingInFileNames": false,
|
|
19
|
-
"noFallthroughCasesInSwitch": false
|
|
20
|
-
}
|
|
21
|
-
}
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
# See https://help.github.com/articles/ignoring-files/ for more about ignoring files.
|
|
2
|
-
|
|
3
|
-
# dependencies
|
|
4
|
-
/node_modules
|
|
5
|
-
/.pnp
|
|
6
|
-
.pnp.js
|
|
7
|
-
.history
|
|
8
|
-
|
|
9
|
-
# testing
|
|
10
|
-
/coverage
|
|
11
|
-
|
|
12
|
-
# next.js
|
|
13
|
-
/.next/
|
|
14
|
-
/out/
|
|
15
|
-
|
|
16
|
-
# production
|
|
17
|
-
/build
|
|
18
|
-
|
|
19
|
-
# misc
|
|
20
|
-
.DS_Store
|
|
21
|
-
*.pem
|
|
22
|
-
|
|
23
|
-
# debug
|
|
24
|
-
npm-debug.log*
|
|
25
|
-
yarn-debug.log*
|
|
26
|
-
yarn-error.log*
|
|
27
|
-
pnpm-lock.yaml
|
|
28
|
-
|
|
29
|
-
# local env files
|
|
30
|
-
.env*.local
|
|
31
|
-
|
|
32
|
-
# vercel
|
|
33
|
-
.vercel
|
|
34
|
-
|
|
35
|
-
# typescript
|
|
36
|
-
*.tsbuildinfo
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"extends": "stylelint-config-standard-scss",
|
|
3
|
-
"rules": {
|
|
4
|
-
"comment-empty-line-before": "never",
|
|
5
|
-
"no-empty-source": null,
|
|
6
|
-
"alpha-value-notation": null,
|
|
7
|
-
"color-function-notation": null,
|
|
8
|
-
"at-rule-no-unknown": [
|
|
9
|
-
true,
|
|
10
|
-
{
|
|
11
|
-
"ignoreAtRules": ["tailwind", "apply", "use"]
|
|
12
|
-
}
|
|
13
|
-
],
|
|
14
|
-
"declaration-block-no-redundant-longhand-properties": null,
|
|
15
|
-
"selector-pseudo-class-no-unknown": [
|
|
16
|
-
true,
|
|
17
|
-
{
|
|
18
|
-
"ignorePseudoClasses": ["global"]
|
|
19
|
-
}
|
|
20
|
-
],
|
|
21
|
-
"selector-class-pattern": null,
|
|
22
|
-
"scss/at-rule-no-unknown": [
|
|
23
|
-
true,
|
|
24
|
-
{
|
|
25
|
-
"ignoreAtRules": ["tailwind", "a pply"]
|
|
26
|
-
}
|
|
27
|
-
]
|
|
28
|
-
}
|
|
29
|
-
}
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
This is a [Next.js](https://nextjs.org/) project bootstrapped with [`create-next-app`](https://github.com/vercel/next.js/tree/canary/packages/create-next-app).
|
|
2
|
-
|
|
3
|
-
## Getting Started
|
|
4
|
-
|
|
5
|
-
First, run the development server:
|
|
6
|
-
|
|
7
|
-
```bash
|
|
8
|
-
npm run dev
|
|
9
|
-
# or
|
|
10
|
-
yarn dev
|
|
11
|
-
# or
|
|
12
|
-
pnpm dev
|
|
13
|
-
```
|
|
14
|
-
|
|
15
|
-
Open [http://localhost:3000](http://localhost:3000) with your browser to see the result.
|
|
16
|
-
|
|
17
|
-
You can start editing the page by modifying `app/page.tsx`. The page auto-updates as you edit the file.
|
|
18
|
-
|
|
19
|
-
This project uses [`next/font`](https://nextjs.org/docs/basic-features/font-optimization) to automatically optimize and load Inter, a custom Google Font.
|
|
20
|
-
|
|
21
|
-
## Learn More
|
|
22
|
-
|
|
23
|
-
To learn more about Next.js, take a look at the following resources:
|
|
24
|
-
|
|
25
|
-
- [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js features and API.
|
|
26
|
-
- [Learn Next.js](https://nextjs.org/learn) - an interactive Next.js tutorial.
|
|
27
|
-
|
|
28
|
-
You can check out [the Next.js GitHub repository](https://github.com/vercel/next.js/) - your feedback and contributions are welcome!
|
|
29
|
-
|
|
30
|
-
## Deploy on Vercel
|
|
31
|
-
|
|
32
|
-
The easiest way to deploy your Next.js app is to use the [Vercel Platform](https://vercel.com/new?utm_medium=default-template&filter=next.js&utm_source=create-next-app&utm_campaign=create-next-app-readme) from the creators of Next.js.
|
|
33
|
-
|
|
34
|
-
Check out our [Next.js deployment documentation](https://nextjs.org/docs/deployment) for more details.
|
|
Binary file
|