Replies: 1 comment
-
Hi @mcroba, ./plugins/styled-components.tsimport createTransformer from '../../src'
export default function createMyTransformer(options: Parameters<typeof createTransformer>[0]) {
return createTransformer({
...options, // this allows to pass options from tsconfig
getDisplayName: (filename, binding) => `${filename}_${binding}` // your logic for display name
// other options if needed
})
} ./tsconfig.json{
"compilerOptions": {
"plugins": [
{
"transform": "./plugins/styled-components.ts",
"type": "config",
"minify": true,
"ssr": true
}
]
}
} |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
How can I configure my tsconfig.json to define the getDisplayName function in order to compile with ttypescript?
Thank you in advance for your help
Beta Was this translation helpful? Give feedback.
All reactions