nuxt-monaco-editor 1.1.3 → 1.1.4

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/CHANGELOG.md CHANGED
@@ -2,6 +2,13 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### [1.1.4](https://github.com/e-chan1007/nuxt-monaco-editor/compare/v1.1.3...v1.1.4) (2023-02-22)
6
+
7
+
8
+ ### Bug Fixes
9
+
10
+ * change the directory to which `monaco-editor` will be copied ([7f88db5](https://github.com/e-chan1007/nuxt-monaco-editor/commit/7f88db5ea359ae0b91ea7664872b9f908f26994a))
11
+
5
12
  ### [1.1.3](https://github.com/e-chan1007/nuxt-monaco-editor/compare/v1.1.3-beta.0...v1.1.3) (2023-01-28)
6
13
 
7
14
 
package/dist/module.json CHANGED
@@ -4,5 +4,5 @@
4
4
  "compatibility": {
5
5
  "nuxt": "^3.1.0"
6
6
  },
7
- "version": "1.1.3"
7
+ "version": "1.1.4"
8
8
  }
package/dist/module.mjs CHANGED
@@ -1,5 +1,5 @@
1
1
  import { fileURLToPath } from 'url';
2
- import { defineNuxtModule, createResolver, extendViteConfig, addPlugin, addComponent, addImports } from '@nuxt/kit';
2
+ import { defineNuxtModule, createResolver, addVitePlugin, addPlugin, addComponent, addImports } from '@nuxt/kit';
3
3
  import { viteStaticCopy } from 'vite-plugin-static-copy';
4
4
 
5
5
 
@@ -27,6 +27,8 @@ const module = defineNuxtModule({
27
27
  },
28
28
  defaults: DEFAULTS,
29
29
  setup(options, nuxt) {
30
+ const isDev = nuxt.options.dev;
31
+ options.dest = (isDev ? "_nuxt_monaco_editor/" : "_nuxt/") + options.dest;
30
32
  const runtimeDir = fileURLToPath(new URL("./runtime", import.meta.url));
31
33
  const { resolve: resolveURL } = createResolver(nuxt.options.app.baseURL);
32
34
  const { resolve } = createResolver(runtimeDir);
@@ -35,18 +37,13 @@ const module = defineNuxtModule({
35
37
  nuxt.options.build.transpile.push(({ isClient }) => isClient ? "monaco-editor" : false);
36
38
  nuxt.options.runtimeConfig.app.__MONACO_EDITOR_LOCALE__ = options.locale;
37
39
  nuxt.options.runtimeConfig.app.__MONACO_EDITOR_LOCATION__ = monacoEditorLocation;
38
- extendViteConfig((config) => {
39
- const viteStaticCopyPlugin = viteStaticCopy({
40
- targets: [{
41
- src: require.resolve("monaco-editor/min/vs/loader.js").replace(/\\/g, "/").replace(/\/vs\/loader\.js$/, "/*"),
42
- dest: options.dest
43
- }]
44
- });
45
- if (!config.plugins) {
46
- config.plugins = [];
47
- }
48
- config.plugins.push(...viteStaticCopyPlugin);
40
+ const viteStaticCopyPlugin = viteStaticCopy({
41
+ targets: [{
42
+ src: require.resolve("monaco-editor/min/vs/loader.js").replace(/\\/g, "/").replace(/\/vs\/loader\.js$/, "/*"),
43
+ dest: options.dest
44
+ }]
49
45
  });
46
+ addVitePlugin(viteStaticCopyPlugin);
50
47
  addPlugin(resolve("plugin.client"));
51
48
  addComponent({ name: options.componentName.codeEditor, filePath: resolve("MonacoEditor.vue") });
52
49
  addComponent({ name: options.componentName.diffEditor, filePath: resolve("MonacoDiffEditor.vue") });
package/package.json CHANGED
@@ -11,7 +11,7 @@
11
11
  "type": "git",
12
12
  "url": "https://github.com/e-chan1007/nuxt-monaco-editor.git"
13
13
  },
14
- "version": "1.1.3",
14
+ "version": "1.1.4",
15
15
  "type": "module",
16
16
  "license": "MIT",
17
17
  "exports": {
@@ -42,28 +42,28 @@
42
42
  "docs:preview": "nuxt preview docs"
43
43
  },
44
44
  "dependencies": {
45
- "@nuxt/kit": "^3.1.1",
45
+ "@nuxt/kit": "^3.2.2",
46
46
  "vite-plugin-static-copy": "^0.13.0"
47
47
  },
48
48
  "devDependencies": {
49
- "@commitlint/cli": "^17.4.2",
50
- "@commitlint/config-conventional": "^17.4.2",
51
- "@nuxt-themes/docus": "^1.6.3",
49
+ "@commitlint/cli": "^17.4.4",
50
+ "@commitlint/config-conventional": "^17.4.4",
51
+ "@nuxt-themes/docus": "^1.8.3",
52
52
  "@nuxt/module-builder": "latest",
53
- "@nuxt/test-utils": "^3.1.1",
53
+ "@nuxt/test-utils": "^3.2.2",
54
54
  "@nuxtjs/eslint-config-typescript": "^12.0.0",
55
- "eslint": "^8.32.0",
56
- "execa": "^6.1.0",
55
+ "eslint": "^8.34.0",
56
+ "execa": "^7.0.0",
57
57
  "husky": "^8.0.3",
58
- "monaco-editor": "^0.34.1",
59
- "nuxt": "^3.1.1",
58
+ "monaco-editor": "^0.35.0",
59
+ "nuxt": "^3.2.2",
60
60
  "pinst": "^3.0.0",
61
- "playwright": "^1.30.0",
61
+ "playwright": "^1.31.0",
62
62
  "remark-cli": "^11.0.0",
63
63
  "remark-lint": "^9.1.1",
64
64
  "remark-preset-lint-recommended": "^6.1.2",
65
65
  "standard-version": "^9.5.0",
66
- "vitest": "^0.28.3"
66
+ "vitest": "^0.28.5"
67
67
  },
68
68
  "peerDependencies": {
69
69
  "monaco-editor": "*"