babel-blade docs

babel-blade docs

  • Docs
  • API
  • Help
  • GitHub
  • Roadmap
  • Blog

›Getting Started

Introduction

  • What is Babel-Blade?
  • The Double Declaration Problem

Usage/API

  • GraphQL Spec By Example

Getting Started

  • As a babel plugin
  • As a babel macro

As a babel plugin

obligatory note: babel-blade is not yet production ready! Please proceed only if you are an early adopter. Feel free to chat with @swyx or check our issues!

Installation

npm install --save-dev babel-plugin-blade

If you want to use it with babel@7, you should also install babel-core@^7.0.0-0 (just to prevent peer dep warnings).

Usage

Via .babelrc (Recommended)

.babelrc

{
  "plugins": ["babel-plugin-blade"]
}

Via CLI

babel --plugins babel-plugin-blade script.js

Via Node API

require('babel-core').transform('code', {
  plugins: ['babel-plugin-blade']
});
← GraphQL Spec By ExampleAs a babel macro →
  • Installation
  • Usage
    • Via .babelrc (Recommended)
    • Via CLI
    • Via Node API
babel-blade docs
Docs
Getting StartedAPI Reference
Community
Twitter
More
BlogGitHubStar
MIT License. Maintained by @swyx