diff --git a/CHANGELOG.md b/CHANGELOG.md index 84ce6ea2d..10d136661 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,17 @@ +# [17.3.0](https://github.com/vuejs/vue-loader/compare/v17.2.2...v17.3.0) (2023-10-07) + + +### Bug Fixes + +* re-use ident of vue rule for template compiler, fixes [#2029](https://github.com/vuejs/vue-loader/issues/2029) ([#2030](https://github.com/vuejs/vue-loader/issues/2030)) ([b50fa56](https://github.com/vuejs/vue-loader/commit/b50fa5665f2cbc1c0b8e18f65dd3adf1dfe848dc)) + + +### Features + +* skip normal css files without scoped flag in stylePostLoader ([#2053](https://github.com/vuejs/vue-loader/issues/2053)) ([98782e7](https://github.com/vuejs/vue-loader/commit/98782e794fadca83b600b047b55aa6f0c230cc25)) + + + ## [17.2.2](https://github.com/vuejs/vue-loader/compare/v17.2.1...v17.2.2) (2023-06-02) diff --git a/package.json b/package.json index 315b624b8..adf20fe75 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "vue-loader", - "version": "17.3.0", + "version": "17.3.1", "license": "MIT", "author": "Evan You", "repository": "vuejs/vue-loader", diff --git a/src/stylePostLoader.ts b/src/stylePostLoader.ts index 59c664d5b..20a8645ac 100644 --- a/src/stylePostLoader.ts +++ b/src/stylePostLoader.ts @@ -10,13 +10,8 @@ const { compileStyle } = compiler const StylePostLoader: LoaderDefinitionFunction = function (source, inMap) { const query = qs.parse(this.resourceQuery.slice(1)) - // skip normal CSS files without scoped flag - if ( - !('vue' in query) || - query.type !== 'style' || - !query.id || - !query.scoped - ) { + // skip normal CSS files + if (!('vue' in query) || query.type !== 'style' || !query.id) { this.callback(null, source, inMap) return } diff --git a/test/fixtures/style-v-bind.vue b/test/fixtures/style-v-bind.vue new file mode 100644 index 000000000..143bdb326 --- /dev/null +++ b/test/fixtures/style-v-bind.vue @@ -0,0 +1,25 @@ + + + + + diff --git a/test/style.spec.ts b/test/style.spec.ts index 4bb998dbe..72fb3cbd3 100644 --- a/test/style.spec.ts +++ b/test/style.spec.ts @@ -198,4 +198,22 @@ test('CSS Modules Extend', async () => { expect(style).toContain(`.${instance.$style.red} {\n color: #FF0000;\n}`) }) -test.todo('experimental