@vanilla-extract/vite-plugin 5.0.6 → 5.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.
@@ -138,7 +138,7 @@ function vanillaExtractPlugin({
|
|
138
138
|
var _compiler2;
|
139
139
|
return (_compiler2 = compiler$1) === null || _compiler2 === void 0 ? void 0 : _compiler2.close();
|
140
140
|
},
|
141
|
-
async transform(code, id) {
|
141
|
+
async transform(code, id, options = {}) {
|
142
142
|
const [validId] = id.split('?');
|
143
143
|
if (!integration.cssFileFilter.test(validId)) {
|
144
144
|
return null;
|
@@ -168,8 +168,8 @@ function vanillaExtractPlugin({
|
|
168
168
|
}
|
169
169
|
};
|
170
170
|
|
171
|
-
// We don't need to watch files in build mode
|
172
|
-
if (isBuild) {
|
171
|
+
// We don't need to watch files or invalidate modules in build mode or during SSR
|
172
|
+
if (isBuild || options.ssr) {
|
173
173
|
return result;
|
174
174
|
}
|
175
175
|
for (const file of watchFiles) {
|
@@ -138,7 +138,7 @@ function vanillaExtractPlugin({
|
|
138
138
|
var _compiler2;
|
139
139
|
return (_compiler2 = compiler$1) === null || _compiler2 === void 0 ? void 0 : _compiler2.close();
|
140
140
|
},
|
141
|
-
async transform(code, id) {
|
141
|
+
async transform(code, id, options = {}) {
|
142
142
|
const [validId] = id.split('?');
|
143
143
|
if (!integration.cssFileFilter.test(validId)) {
|
144
144
|
return null;
|
@@ -168,8 +168,8 @@ function vanillaExtractPlugin({
|
|
168
168
|
}
|
169
169
|
};
|
170
170
|
|
171
|
-
// We don't need to watch files in build mode
|
172
|
-
if (isBuild) {
|
171
|
+
// We don't need to watch files or invalidate modules in build mode or during SSR
|
172
|
+
if (isBuild || options.ssr) {
|
173
173
|
return result;
|
174
174
|
}
|
175
175
|
for (const file of watchFiles) {
|
@@ -130,7 +130,7 @@ function vanillaExtractPlugin({
|
|
130
130
|
var _compiler2;
|
131
131
|
return (_compiler2 = compiler) === null || _compiler2 === void 0 ? void 0 : _compiler2.close();
|
132
132
|
},
|
133
|
-
async transform(code, id) {
|
133
|
+
async transform(code, id, options = {}) {
|
134
134
|
const [validId] = id.split('?');
|
135
135
|
if (!cssFileFilter.test(validId)) {
|
136
136
|
return null;
|
@@ -160,8 +160,8 @@ function vanillaExtractPlugin({
|
|
160
160
|
}
|
161
161
|
};
|
162
162
|
|
163
|
-
// We don't need to watch files in build mode
|
164
|
-
if (isBuild) {
|
163
|
+
// We don't need to watch files or invalidate modules in build mode or during SSR
|
164
|
+
if (isBuild || options.ssr) {
|
165
165
|
return result;
|
166
166
|
}
|
167
167
|
for (const file of watchFiles) {
|
package/package.json
CHANGED