@dword-design/base-config-nuxt 4.0.5 → 4.0.7
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/dist/eslint.config.js +3 -0
- package/dist/index.js +27 -3
- package/package.json +1 -1
package/dist/eslint.config.js
CHANGED
package/dist/index.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import depcheckParserSass from '@dword-design/depcheck-parser-sass';
|
|
2
2
|
import endent from "@dword-design/functions/dist/endent.js";
|
|
3
|
+
import javascript from "@dword-design/functions/dist/endent.js";
|
|
3
4
|
import packageName from 'depcheck-package-name';
|
|
4
5
|
import depcheckParserVue from 'depcheck-parser-vue';
|
|
5
6
|
import { globby } from 'globby';
|
|
@@ -29,9 +30,9 @@ export default {
|
|
|
29
30
|
},
|
|
30
31
|
specials: [depcheckSpecial]
|
|
31
32
|
},
|
|
32
|
-
editorIgnore: ['.eslintcache', '.stylelintcache', '.stylelintrc.json', '.nuxt', 'app.vue', 'dist', 'nuxt.config.js'],
|
|
33
|
+
editorIgnore: ['.eslintcache', '.stylelintcache', '.stylelintrc.json', '.nuxt', '.output', 'app.vue', 'dist', 'nuxt.config.js'],
|
|
33
34
|
eslintConfig,
|
|
34
|
-
gitignore: ['/.eslintcache', '/.nuxt', '/.stylelintcache', '/app.vue', '/dist', '/nuxt.config.js'],
|
|
35
|
+
gitignore: ['/.eslintcache', '/.nuxt', '/.output', '/.stylelintcache', '/app.vue', '/dist', '/nuxt.config.js'],
|
|
35
36
|
lint,
|
|
36
37
|
nodeVersion: 18,
|
|
37
38
|
npmPublish: true,
|
|
@@ -69,11 +70,12 @@ export default {
|
|
|
69
70
|
})
|
|
70
71
|
</script>
|
|
71
72
|
`,
|
|
72
|
-
'nuxt.config.js':
|
|
73
|
+
'nuxt.config.js': javascript`
|
|
73
74
|
import projectModule from '${projectModulePath}'
|
|
74
75
|
import jiti from 'jiti'
|
|
75
76
|
import dotenv from '@dword-design/dotenv-json-extended'
|
|
76
77
|
import jitiBabelTransform from '@dword-design/jiti-babel-transform'
|
|
78
|
+
import { transform } from '@babel/core'
|
|
77
79
|
import { babel } from '${packageName`@rollup/plugin-babel`}'
|
|
78
80
|
|
|
79
81
|
dotenv.config()
|
|
@@ -103,6 +105,28 @@ export default {
|
|
|
103
105
|
modules: [
|
|
104
106
|
[projectModule, options],
|
|
105
107
|
],
|
|
108
|
+
vite: {
|
|
109
|
+
plugins: [
|
|
110
|
+
{
|
|
111
|
+
transform: (code, id) => {
|
|
112
|
+
if (id.endsWith('.vue')) {
|
|
113
|
+
return transform(code, {
|
|
114
|
+
plugins: [
|
|
115
|
+
['@babel/proposal-pipeline-operator', { proposal: 'fsharp'}],
|
|
116
|
+
],
|
|
117
|
+
})
|
|
118
|
+
}
|
|
119
|
+
},
|
|
120
|
+
}
|
|
121
|
+
],
|
|
122
|
+
vue: {
|
|
123
|
+
script: {
|
|
124
|
+
babelParserPlugins: [
|
|
125
|
+
['pipelineOperator', { proposal: 'fsharp' }],
|
|
126
|
+
],
|
|
127
|
+
},
|
|
128
|
+
},
|
|
129
|
+
},
|
|
106
130
|
}
|
|
107
131
|
`
|
|
108
132
|
});
|