Skip to content

Commit

Permalink
Switch to simpler preact alias
Browse files Browse the repository at this point in the history
  • Loading branch information
apetresc committed Aug 17, 2022
1 parent 3f7a8e4 commit 75f6b36
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,10 @@ module.exports = (env, argv) => ({

resolve: {
alias: {
react:
argv.mode === 'production'
? path.join(__dirname, 'node_modules/preact/dist/preact.min.js')
: 'preact',
'prop-types': path.join(__dirname, 'src/modules/shims/prop-types.js')
react: 'preact/compat',
'react-dom/test-utils': 'preact/test-utils',
'react-dom': 'preact/compat',
'react/jsx-runtime': 'preact/jsx-runtime'
}
},

Expand Down

0 comments on commit 75f6b36

Please sign in to comment.