Skip to content
Discussion options

You must be logged in to vote

I guess having the plugin that would check content from other files will be a significant change that could become a pain to maintain, but is that an option ?

Currently I did this script that is taking my files from the folder the script is in (in my case src/tokens) and take all files that doesn't end with .stylex.ts and generate the same files by reexporting export const *Tokens as export const ${baseName} = css.defineVars(${fullName}) which is enough to make me happy for now.

// https://github.com/facebook/react-strict-dom/discussions/303

import * as fs from "fs";
import * as path from "path";
import { fileURLToPath } from "url";
// @ts-expect-error import.meta just works when using n…

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@MoOx
Comment options

Answer selected by MoOx
@necolas
Comment options

necolas May 9, 2025
Collaborator

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants