force esm version of unicode-segmenter on web
This commit is contained in:
@@ -23,6 +23,10 @@ module.exports = async function (env, argv) {
|
||||
config = withAlias(config, {
|
||||
'react-native$': 'react-native-web',
|
||||
'react-native-webview': 'react-native-web-webview',
|
||||
// Force ESM version
|
||||
'unicode-segmenter/grapheme': require
|
||||
.resolve('unicode-segmenter/grapheme')
|
||||
.replace(/\.cjs$/, '.js'),
|
||||
})
|
||||
config.module.rules = [
|
||||
...(config.module.rules || []),
|
||||
|
||||
Reference in New Issue
Block a user