@superstyling/expo
v0.2.0
Published
Expo integration for Superstyling — Metro/Babel config, teleport host registration
Maintainers
Readme
@superstyling/expo
Expo integration for Superstyling. Ships the required Tamagui native setup side-effects (teleport host, gesture handler, worklets, safe-area, keyboard), a Babel preset with the Tamagui compiler, a Metro config helper, and an Expo config plugin.
Install
yarn add @superstyling/core @superstyling/expoUsage
app/_layout.tsx — run the Tamagui native setup side-effect once at the app root:
import "@superstyling/expo/setup";babel.config.js:
const { babelPreset } = require("@superstyling/expo/babel-plugin");
module.exports = {
presets: [...babelPreset({ components: ["@superstyling/core"], config: "./tamagui.config.ts" })],
};metro.config.js:
const { getDefaultConfig } = require("expo/metro-config");
const { withSuperStylingMetro } = require("@superstyling/expo/metro-config");
module.exports = withSuperStylingMetro(getDefaultConfig(__dirname), {
components: ["@superstyling/core"],
config: "./tamagui.config.ts",
});Docs
See the Expo getting-started guide.
License
MIT
