@astrojs/compiler 0.23.5 → 0.25.0
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 +20 -0
- package/astro.wasm +0 -0
- package/package.json +1 -1
- package/shared/types.d.ts +6 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,25 @@
|
|
|
1
1
|
# @astrojs/compiler
|
|
2
2
|
|
|
3
|
+
## 0.25.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 6446ea3: Make Astro styles being printed after user imports
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- 51bc60f: Fix edge cases with `getStaticPaths` where valid JS syntax was improperly handled
|
|
12
|
+
|
|
13
|
+
## 0.24.0
|
|
14
|
+
|
|
15
|
+
### Minor Changes
|
|
16
|
+
|
|
17
|
+
- 6ebcb4f: Allow preprocessStyle to return an error
|
|
18
|
+
|
|
19
|
+
### Patch Changes
|
|
20
|
+
|
|
21
|
+
- abda605: Include filename when calculating scope
|
|
22
|
+
|
|
3
23
|
## 0.23.5
|
|
4
24
|
|
|
5
25
|
### Patch Changes
|
package/astro.wasm
CHANGED
|
Binary file
|
package/package.json
CHANGED
package/shared/types.d.ts
CHANGED
|
@@ -4,6 +4,9 @@ export interface PreprocessorResult {
|
|
|
4
4
|
code: string;
|
|
5
5
|
map?: string;
|
|
6
6
|
}
|
|
7
|
+
export interface PreprocessorError {
|
|
8
|
+
error: string;
|
|
9
|
+
}
|
|
7
10
|
export interface ParseOptions {
|
|
8
11
|
position?: boolean;
|
|
9
12
|
}
|
|
@@ -12,6 +15,7 @@ export interface TransformOptions {
|
|
|
12
15
|
site?: string;
|
|
13
16
|
sourcefile?: string;
|
|
14
17
|
pathname?: string;
|
|
18
|
+
moduleId?: string;
|
|
15
19
|
sourcemap?: boolean | 'inline' | 'external' | 'both';
|
|
16
20
|
compact?: boolean;
|
|
17
21
|
/**
|
|
@@ -19,7 +23,7 @@ export interface TransformOptions {
|
|
|
19
23
|
*/
|
|
20
24
|
as?: 'document' | 'fragment';
|
|
21
25
|
projectRoot?: string;
|
|
22
|
-
preprocessStyle?: (content: string, attrs: Record<string, string>) => Promise<PreprocessorResult>;
|
|
26
|
+
preprocessStyle?: (content: string, attrs: Record<string, string>) => null | Promise<PreprocessorResult | PreprocessorError>;
|
|
23
27
|
experimentalStaticExtraction?: boolean;
|
|
24
28
|
}
|
|
25
29
|
export declare type HoistedScript = {
|
|
@@ -45,6 +49,7 @@ export interface TransformResult {
|
|
|
45
49
|
code: string;
|
|
46
50
|
map: string;
|
|
47
51
|
scope: string;
|
|
52
|
+
styleError: string[];
|
|
48
53
|
}
|
|
49
54
|
export interface TSXResult {
|
|
50
55
|
code: string;
|