We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I really want to use that package with my vue-cli configuration. Sadly it is not possible/does not work.
I implemented the transformer like this (because I know no other possibility with webpack-chain)
// vue.config.js function graphqltransformer() {} graphqltransformer.__expression = `() => ({before: [require('` + require.resolve('ts-transform-graphql-tag') + `').getTransformer()]})` module.exports = { // ... chainWebpack: config => { // ... config.module .rule('ts') .use('ts-loader') .tap(options => { options.getCustomTransformers = graphqltransformer return options }) config.module .rule('tsx') .use('ts-loader') .tap(options => { options.getCustomTransformers = graphqltransformer return options }) } }
The generated webpack.config.js looks quite good:
// ... /* config.module.rule('ts').use('ts-loader') */ { loader: 'ts-loader', options: { transpileOnly: true, appendTsSuffixTo: [ '\\.vue$' ], happyPackMode: false, getCustomTransformers: () => ({before: [require('/home/patrick/dev/bodnet/node_modules/ts-transform-graphql-tag/dist/index.js').getTransformer()]}) } } // ...
But when I build the project using yarn build the gql tags are strings like before.
yarn build
The text was updated successfully, but these errors were encountered:
No branches or pull requests
I really want to use that package with my vue-cli configuration.
Sadly it is not possible/does not work.
I implemented the transformer like this (because I know no other possibility with webpack-chain)
The generated webpack.config.js looks quite good:
But when I build the project using
yarn build
the gql tags are strings like before.The text was updated successfully, but these errors were encountered: