@vue/language-core 2.1.0 → 2.1.2

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.
@@ -31,7 +31,7 @@ exports.codeFeatures = {
31
31
  };
32
32
  function* generateScript(options) {
33
33
  const ctx = (0, context_1.createScriptCodegenContext)(options);
34
- yield `/// <reference types="${options.vueCompilerOptions.lib}/__globalTypes_${options.vueCompilerOptions.target}_${options.vueCompilerOptions.strictTemplates}" />${common_1.newLine}`;
34
+ yield `/// <reference types="${options.vueCompilerOptions.lib}/dist/__globalTypes_${options.vueCompilerOptions.target}_${options.vueCompilerOptions.strictTemplates}.d.ts" />${common_1.newLine}`;
35
35
  if (options.sfc.script?.src) {
36
36
  yield* (0, src_1.generateSrc)(options.sfc.script, options.sfc.script.src);
37
37
  }
package/lib/utils/ts.js CHANGED
@@ -156,7 +156,7 @@ function getPartialVueCompilerOptions(ts, tsConfigSourceFile) {
156
156
  }
157
157
  function resolveVueCompilerOptions(vueOptions) {
158
158
  const target = vueOptions.target ?? 3.3;
159
- const lib = vueOptions.lib || (target < 2.7 ? '@vue/runtime-dom' : 'vue');
159
+ const lib = vueOptions.lib ?? 'vue';
160
160
  return {
161
161
  ...vueOptions,
162
162
  target,
@@ -172,7 +172,7 @@ function resolveVueCompilerOptions(vueOptions) {
172
172
  htmlAttributes: vueOptions.htmlAttributes ?? ['aria-*'],
173
173
  optionsWrapper: vueOptions.optionsWrapper ?? (target >= 2.7
174
174
  ? [`(await import('${lib}')).defineComponent(`, `)`]
175
- : [`(await import('vue')).default.extend(`, `)`]),
175
+ : [`(await import('${lib}')).default.extend(`, `)`]),
176
176
  macros: {
177
177
  defineProps: ['defineProps'],
178
178
  defineSlots: ['defineSlots'],
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vue/language-core",
3
- "version": "2.1.0",
3
+ "version": "2.1.2",
4
4
  "license": "MIT",
5
5
  "files": [
6
6
  "**/*.js",
@@ -36,5 +36,5 @@
36
36
  "optional": true
37
37
  }
38
38
  },
39
- "gitHead": "510063740b90b64caedaee1f0bde70974613a92c"
39
+ "gitHead": "4e4b839ea20ae11a2aef7ee9206465cb60a4be53"
40
40
  }