mirror of
https://github.com/expo/config-plugins.git
synced 2026-11-14 10:08:06 -10:00
* chore: add `oxlint` and `oxfmt` * chore: switch lint to oxlint Root oxlint.config.mjs extends oxlint-config-universe/node. Each package re-exports it and runs oxlint --config oxlint.config.mjs ., since oxlint does not discover a root .mjs config from a package directory. CI lints with --deny-warnings and checks formatting with oxfmt. Removes eslintrc.base.js, every .eslintrc.js, and the eslint, eslint-config-universe and prettier devDependencies. Bumps oxlint and oxfmt and aligns .oxfmtrc.json with expo/expo, ignoring the generated SettingsPlist.ts that json2ts rewrites in prettier's default style. Also runs pnpm dedupe. The package.json files in this commit carry the oxfmt key reorder as well; the rest of the reformat is its own commit. * chore: format with oxfmt Mechanical reformat of the repo with oxfmt. No code changes.
@config-plugins/%CONFIG_PLUGIN%
Expo Config Plugin to auto-configure %NPM_MODULE% when the native code is generated (npx expo prebuild).
Versioning
expo |
%NPM_MODULE% |
@config-plugins/%CONFIG_PLUGIN% |
|---|---|---|
| %SDK_VERSION%.0.0 | 1.0.0 | ^1.0.0 |
Expo installation
This package cannot be used in the "Expo Go" app because it requires custom native code.
First install the package with yarn, npm, or npx expo install.
npx expo install %NPM_MODULE% @config-plugins/%CONFIG_PLUGIN%
After installing this npm package, add the config plugin to the plugins array of your app.json or app.config.js:
{
"expo": {
"plugins": ["@config-plugins/%CONFIG_PLUGIN%"]
}
}
Next, rebuild your app as described in the "Adding custom native code" guide.
API
The plugin provides props for extra customization. Every time you change the props or plugins, you'll need to rebuild (and prebuild) the native app. If no extra properties are added, defaults will be used.
foobar(boolean): Does XYZ. Defaultfalse.
Example
{
"expo": {
"plugins": [
[
"@config-plugins/%CONFIG_PLUGIN%",
{
// props ...
}
]
]
}
}