Skip to content

Commit 67d10dc

Browse files
committed
fix: context reloading after config change
1 parent 1ba7936 commit 67d10dc

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

packages/language-server/src/setup-builder.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,8 @@ export function setupBuilder(
4848
const ctx = builder.context
4949
if (!ctx) return
5050

51+
console.log('🐼 Context reloaded for:', configPath)
52+
ref.context = ctx
5153
const tokenNames = Array.from(new Set(ctx.tokens.allTokens.map((token) => token.path.slice(1).join('.'))))
5254
connection.sendNotification('$/panda-token-names', { configPath, tokenNames })
5355
})
@@ -100,6 +102,7 @@ export function setupBuilder(
100102
const builder = builderResolver.get(filepath)
101103
if (!builder || !builder.context) return
102104

105+
console.log('🐼 Context loaded for:', filepath)
103106
ref.context = builder.context
104107

105108
return ref.context
@@ -111,6 +114,7 @@ export function setupBuilder(
111114
const builder = builderResolver.get(filepath)
112115
if (!builder || !builder.context) return
113116

117+
console.log('🐼 Found panda context! ✅ at', filepath)
114118
ref.context = builder.context
115119

116120
return ref.context

0 commit comments

Comments
 (0)