File tree Expand file tree Collapse file tree 3 files changed +6
-4
lines changed Expand file tree Collapse file tree 3 files changed +6
-4
lines changed Original file line number Diff line number Diff line change 5
5
"private" : true ,
6
6
"scripts" : {
7
7
"astro" : " astro" ,
8
- "build_with_check" : " astro check && npm run build" ,
8
+ "build_with_check" : " astro check && pnpm run build" ,
9
9
"build" : " astro build && cp _headers ./dist/" ,
10
10
"dev" : " astro dev" ,
11
11
"preview" : " astro preview" ,
Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ import { defineCollection } from 'astro:content';
3
3
4
4
const tutorial = defineCollection ( {
5
5
type : 'content' ,
6
- schema : tutorialSchema . or ( partSchema ) . or ( chapterSchema ) . or ( lessonSchema ) ,
6
+ schema : tutorialSchema . strict ( ) . or ( partSchema . strict ( ) ) . or ( chapterSchema . strict ( ) ) . or ( lessonSchema . strict ( ) ) ,
7
7
} ) ;
8
8
9
9
export const collections = { tutorial } ;
Original file line number Diff line number Diff line change 1
1
import { theme } from '@tutorialkit/astro' ;
2
2
import transformerDirectives from '@unocss/transformer-directives' ;
3
- import { globSync } from 'fast-glob' ;
3
+ import { globSync , convertPathToPattern } from 'fast-glob' ;
4
4
import fs from 'node:fs/promises' ;
5
5
import { basename , dirname , join } from 'node:path' ;
6
6
import { defineConfig , presetIcons , presetUno } from 'unocss' ;
@@ -23,7 +23,9 @@ const customIconCollection = iconPaths.reduce(
23
23
export default defineConfig ( {
24
24
theme,
25
25
content : {
26
- inline : globSync ( join ( require . resolve ( '@tutorialkit/components-react' ) , '../**/*.js' ) ) . map ( ( filePath ) => {
26
+ inline : globSync (
27
+ `${ convertPathToPattern ( join ( require . resolve ( '@tutorialkit/components-react' ) , '..' ) ) } /**/*.js` ,
28
+ ) . map ( ( filePath ) => {
27
29
return ( ) => fs . readFile ( filePath , { encoding : 'utf8' } ) ;
28
30
} ) ,
29
31
} ,
You can’t perform that action at this time.
0 commit comments