File tree Expand file tree Collapse file tree 1 file changed +0
-17
lines changed Expand file tree Collapse file tree 1 file changed +0
-17
lines changed Original file line number Diff line number Diff line change @@ -80,23 +80,6 @@ export function traverseChildren(
8080 return false ;
8181}
8282
83- export async function hasRenderSSRCall (
84- code : string ,
85- filename : string ,
86- ) : Promise < boolean > {
87- try {
88- const { parseSync } = await import ( "oxc-parser" ) ;
89- const ast = parseSync ( filename , code ) ;
90- return hasRenderSSRCallInAST ( ast as unknown as Node , code ) ;
91- } catch ( error ) {
92- console . warn (
93- `Failed to parse ${ filename } for renderSSR detection, falling back to string check:` ,
94- error ,
95- ) ;
96- return code . includes ( "renderSSR" ) ;
97- }
98- }
99-
10083export function hasRenderSSRCallInAST ( ast : Node , code : string ) : boolean {
10184 const renderSSRIdentifiers = new Set < string > ( [ "renderSSR" ] ) ;
10285 let hasRenderSSRCallInCode = false ;
You can’t perform that action at this time.
0 commit comments