Skip to content
Source
Sign inSign up
TanStack/router

fix: compile directive replacements #5450

Mergedschiller-manuel(GitHub profile, opens in a new tab)merged 4 commits intomain fromrefs/pull/5450/headmerged by schiller-manuel(GitHub profile, opens in a new tab)

Showing 2 changed files with 39 additions and 45 deletions (loading 1).

x
0 of 2 viewed, 2 left
39 additions and 45 deletionspackages/directive-functions-plugin/src/compilers.tsModified
View file
@@ -68,6 +68,7 @@
const directiveFnsById = findDirectives(ast, {
...opts,
directiveSplitParam,
+ isDirectiveSplitParam,
})
​
// Add runtime code if there are directives
@@ -224,6 +225,7 @@
directiveSplitParam: string
filename: string
root: string
+ isDirectiveSplitParam: boolean
): Record<string, DirectiveFn> {
const directiveFnsById: Record<string, DirectiveFn> = {}
@@ -241,6 +243,9 @@
const hasFileDirective = ast.program.directives.some(
(directive) => directive.value.value === opts.directive,
+ const compileDirectiveOpts = {
+ isDirectiveSplitParam: opts.isDirectiveSplitParam,
+ }