-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
/
Copy pathbabel.config.js
31 lines (28 loc) · 916 Bytes
/
babel.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
const path = require('path');
const pak = require('../package.json');
module.exports = function (api) {
api.cache(true);
return {
presets: ['babel-preset-expo'],
plugins: [
[
'module-resolver',
{
extensions: ['.tsx', '.ts', '.js', '.json'],
alias: {
[`${pak.name}/package.json`]: path.join(
__dirname,
'..',
'package.json'
),
// For development, we want to alias the library to the source
[pak.name]: path.join(__dirname, '..', 'src'),
'react-native-vector-icons': '@expo/vector-icons', //Fixes issue with icons not showing up on web (I also had to add @expo/vector-icons to react-native-paper devDependencies)
},
},
],
['@babel/plugin-proposal-export-namespace-from'],
['react-native-reanimated/plugin'],
],
};
};