• Version 2.8.5
  • Published
  • 5.38 kB
  • 1 dependency
  • MIT license


npm i @types/babel-plugin-macros
yarn add @types/babel-plugin-macros
pnpm add @types/babel-plugin-macros


TypeScript definitions for babel-plugin-macros



function babelPluginMacros

babelPluginMacros: typeof babelPluginMacros;

    function createMacro

    createMacro: (handler: MacroHandler, options?: Options) => any;


      class MacroError

      class MacroError extends Error {}


        interface MacroParams

        interface MacroParams {}

          property babel

          babel: typeof Babel;

            property config

            config?: { [key: string]: any } | undefined;

              property references

              references: { default: Babel.NodePath[] } & References;

                property state

                state: Babel.PluginPass;

                  interface Options

                  interface Options {}

                    property configName

                    configName?: string | undefined;

                      interface References

                      interface References {}

                        index signature

                        [key: string]: Babel.NodePath[];

                          Type Aliases

                          type MacroHandler

                          type MacroHandler = (params: MacroParams) => void;

                            Package Files (1)

                            Dependencies (1)

                            Dev Dependencies (0)

                            No dev dependencies.

                            Peer Dependencies (0)

                            No peer dependencies.


                            To add a badge like this onejsDocs.io badgeto your package's README, use the codes available below.

                            You may also use Shields.io to create a custom badge linking to https://www.jsdocs.io/package/@types/babel-plugin-macros.

                            • Markdown
                            • HTML
                              <a href="https://www.jsdocs.io/package/@types/babel-plugin-macros"><img src="https://img.shields.io/badge/jsDocs.io-reference-blue" alt="jsDocs.io"></a>