create-blocklet 0.5.13 → 0.5.15

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-blocklet",
3
- "version": "0.5.13",
3
+ "version": "0.5.15",
4
4
  "exports": "./index.js",
5
5
  "type": "module",
6
6
  "repository": "git@github.com:blocklet/create-blocklet.git",
@@ -30,7 +30,8 @@ if (isProduction) {
30
30
  app.use(express.static(staticDir, { maxAge: '30d', index: false }));
31
31
  app.use(fallback('index.html', { root: staticDir }));
32
32
 
33
- app.use((err, req, res) => {
33
+ // eslint-disable-next-line no-unused-vars
34
+ app.use((err, req, res, next) => {
34
35
  logger.error(err.stack);
35
36
  res.status(500).send('Something broke!');
36
37
  });
@@ -71,7 +71,7 @@
71
71
  "npm-run-all": "^4.1.5",
72
72
  "prettier": "^2.8.3",
73
73
  "vite": "^3.2.5",
74
- "vite-plugin-blocklet": "^0.5.13",
74
+ "vite-plugin-blocklet": "^0.5.15",
75
75
  "vite-plugin-svgr": "^2.4.0",
76
76
  "zx": "^7.1.1"
77
77
  }
@@ -1,7 +1,9 @@
1
+ const { join } = require('path');
2
+
1
3
  module.exports = {
2
4
  root: true,
3
5
  extends: '@arcblock/eslint-config-ts',
4
6
  parserOptions: {
5
- project: 'tsconfig.json',
7
+ project: [join(__dirname, 'tsconfig.eslint.json'), join(__dirname, 'tsconfig.json')],
6
8
  },
7
9
  };
@@ -36,7 +36,8 @@ if (isProduction) {
36
36
  app.use(express.static(staticDir, { maxAge: '30d', index: false }));
37
37
  app.use(fallback('index.html', { root: staticDir }));
38
38
 
39
- app.use(<ErrorRequestHandler>((err, _, res) => {
39
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
40
+ app.use(<ErrorRequestHandler>((err, req, res, next) => {
40
41
  logger.error(err.stack);
41
42
  res.status(500).send('Something broke!');
42
43
  }));
@@ -82,11 +82,15 @@
82
82
  "ts-node": "^10.9.1",
83
83
  "typescript": "^4.9.4",
84
84
  "vite": "^3.2.5",
85
- "vite-plugin-blocklet": "^0.5.13",
85
+ "vite-plugin-blocklet": "^0.5.15",
86
86
  "vite-plugin-svgr": "^2.4.0",
87
87
  "zx": "^7.1.1"
88
88
  },
89
89
  "importSort": {
90
+ ".js, .jsx, .mjs": {
91
+ "parser": "babylon",
92
+ "style": "module"
93
+ },
90
94
  ".ts, .tsx": {
91
95
  "style": "module",
92
96
  "parser": "typescript"
@@ -1,5 +1,7 @@
1
- import { BrowserRouter as Router, Navigate, Route, Routes } from 'react-router-dom';
2
1
  import './app.css';
2
+
3
+ import { Navigate, Route, BrowserRouter as Router, Routes } from 'react-router-dom';
4
+
3
5
  import About from './pages/about';
4
6
  import Home from './pages/home';
5
7
 
@@ -1,4 +1,5 @@
1
1
  import ReactDOM from 'react-dom/client';
2
+
2
3
  import App from './app';
3
4
 
4
5
  const root = ReactDOM.createRoot(document.getElementById('app')!);
@@ -0,0 +1,7 @@
1
+ {
2
+ "extends": "./tsconfig",
3
+ "compilerOptions": {
4
+ "noEmit": true
5
+ },
6
+ "include": [".eslintrc.js"]
7
+ }
@@ -34,7 +34,8 @@ if (isProduction) {
34
34
  app.use(express.static(staticDir, { maxAge: '30d', index: false }));
35
35
  app.use(fallback('index.html', { root: staticDir }));
36
36
 
37
- app.use((err, req, res) => {
37
+ // eslint-disable-next-line no-unused-vars
38
+ app.use((err, req, res, next) => {
38
39
  logger.error(err.stack);
39
40
  res.status(500).send('Something broke!');
40
41
  });
@@ -72,7 +72,7 @@
72
72
  "prettier": "^2.8.3",
73
73
  "rimraf": "^3.0.2",
74
74
  "vite": "^3.2.5",
75
- "vite-plugin-blocklet": "^0.5.13",
75
+ "vite-plugin-blocklet": "^0.5.15",
76
76
  "vite-plugin-svgr": "^2.4.0",
77
77
  "zx": "^7.1.1"
78
78
  }
@@ -53,7 +53,7 @@
53
53
  "prettier": "^2.8.3",
54
54
  "rimraf": "^3.0.2",
55
55
  "vite": "^3.2.5",
56
- "vite-plugin-blocklet": "^0.5.13",
56
+ "vite-plugin-blocklet": "^0.5.15",
57
57
  "vite-plugin-svgr": "^2.4.0",
58
58
  "zx": "^7.1.1"
59
59
  }
@@ -30,7 +30,8 @@ if (isProduction) {
30
30
  app.use(express.static(staticDir, { maxAge: '30d', index: false }));
31
31
  app.use(fallback('index.html', { root: staticDir }));
32
32
 
33
- app.use((err, req, res) => {
33
+ // eslint-disable-next-line no-unused-vars
34
+ app.use((err, req, res, next) => {
34
35
  logger.error(err.stack);
35
36
  res.status(500).send('Something broke!');
36
37
  });
@@ -33,7 +33,7 @@
33
33
  "prettier": "^2.8.3",
34
34
  "rimraf": "^3.0.2",
35
35
  "vite": "^3.2.5",
36
- "vite-plugin-blocklet": "^0.5.13",
36
+ "vite-plugin-blocklet": "^0.5.15",
37
37
  "vite-plugin-solid": "^2.5.0",
38
38
  "zx": "^7.1.1"
39
39
  },
@@ -29,7 +29,7 @@
29
29
  "prettier": "^2.8.3",
30
30
  "rimraf": "^3.0.2",
31
31
  "vite": "^3.2.5",
32
- "vite-plugin-blocklet": "^0.5.13",
32
+ "vite-plugin-blocklet": "^0.5.15",
33
33
  "vite-plugin-solid": "^2.5.0",
34
34
  "zx": "^7.1.1"
35
35
  },
@@ -30,7 +30,8 @@ if (isProduction) {
30
30
  app.use(express.static(staticDir, { maxAge: '30d', index: false }));
31
31
  app.use(fallback('index.html', { root: staticDir }));
32
32
 
33
- app.use((err, req, res) => {
33
+ // eslint-disable-next-line no-unused-vars
34
+ app.use((err, req, res, next) => {
34
35
  logger.error(err.stack);
35
36
  res.status(500).send('Something broke!');
36
37
  });
@@ -47,7 +47,7 @@
47
47
  "rimraf": "^3.0.2",
48
48
  "svelte": "^3.55.1",
49
49
  "vite": "^3.2.5",
50
- "vite-plugin-blocklet": "^0.5.13",
50
+ "vite-plugin-blocklet": "^0.5.15",
51
51
  "vite-plugin-html": "^3.2.0",
52
52
  "zx": "^7.1.1"
53
53
  },
@@ -30,7 +30,7 @@
30
30
  "rimraf": "^3.0.2",
31
31
  "svelte": "^3.55.1",
32
32
  "vite": "^3.2.5",
33
- "vite-plugin-blocklet": "^0.5.13",
33
+ "vite-plugin-blocklet": "^0.5.15",
34
34
  "zx": "^7.1.1"
35
35
  },
36
36
  "lint-staged": {
@@ -30,7 +30,8 @@ if (isProduction) {
30
30
  app.use(express.static(staticDir, { maxAge: '30d', index: false }));
31
31
  app.use(fallback('index.html', { root: staticDir }));
32
32
 
33
- app.use((err, req, res) => {
33
+ // eslint-disable-next-line no-unused-vars
34
+ app.use((err, req, res, next) => {
34
35
  logger.error(err.stack);
35
36
  res.status(500).send('Something broke!');
36
37
  });
@@ -49,7 +49,7 @@
49
49
  "prettier": "^2.8.3",
50
50
  "rimraf": "^3.0.2",
51
51
  "vite": "^3.2.5",
52
- "vite-plugin-blocklet": "^0.5.13",
52
+ "vite-plugin-blocklet": "^0.5.15",
53
53
  "zx": "^7.1.1"
54
54
  },
55
55
  "lint-staged": {
@@ -31,7 +31,7 @@
31
31
  "prettier": "^2.8.3",
32
32
  "rimraf": "^3.0.2",
33
33
  "vite": "^3.2.5",
34
- "vite-plugin-blocklet": "^0.5.13",
34
+ "vite-plugin-blocklet": "^0.5.15",
35
35
  "zx": "^7.1.1"
36
36
  },
37
37
  "lint-staged": {
@@ -30,7 +30,8 @@ if (isProduction) {
30
30
  app.use(express.static(staticDir, { maxAge: '30d', index: false }));
31
31
  app.use(fallback('index.html', { root: staticDir }));
32
32
 
33
- app.use((err, req, res) => {
33
+ // eslint-disable-next-line no-unused-vars
34
+ app.use((err, req, res, next) => {
34
35
  logger.error(err.stack);
35
36
  res.status(500).send('Something broke!');
36
37
  });
@@ -49,7 +49,7 @@
49
49
  "prettier": "^2.8.3",
50
50
  "rimraf": "^3.0.2",
51
51
  "vite": "^3.2.5",
52
- "vite-plugin-blocklet": "^0.5.13",
52
+ "vite-plugin-blocklet": "^0.5.15",
53
53
  "zx": "^7.1.1"
54
54
  },
55
55
  "lint-staged": {
@@ -31,7 +31,7 @@
31
31
  "prettier": "^2.8.3",
32
32
  "rimraf": "^3.0.2",
33
33
  "vite": "^3.2.5",
34
- "vite-plugin-blocklet": "^0.5.13",
34
+ "vite-plugin-blocklet": "^0.5.15",
35
35
  "zx": "^7.1.1"
36
36
  },
37
37
  "lint-staged": {