Skip to main content

Getting Started

Installation#

yarn add skyle
  • Latest version tested with React-Native versions 0.63+

Enabling Decorators#

TypeScript#

Enable the compiler option "experimentalDecorators": true in your tsconfig.json.

Babel 7#

Install support for decorators:

yarn add -D @babel/plugin-proposal-class-properties @babel/plugin-proposal-decorators

And enable it in your babel.config.js file (note that the order is important):

{
"plugins": [
["@babel/plugin-proposal-decorators", { "legacy": true }],
["@babel/plugin-proposal-class-properties", { "loose": false }]
]
}