1.1.1 • Published 11 months ago

@styils/babel-plugin v1.1.1

Weekly downloads
-
License
MIT
Repository
github
Last release
11 months ago

@styils/babel-plugin

This is required for sourcemap

Use

// .babelrc
// Make sure to put it first to make the sourcemap more readable
{
  plugins: ['@styils']
}

Custom transform

Refer

Parameter

export interface Options {
  identifier?: {
    styled?: string
    createGlobal?: string
  }
  importPaths?: string | RegExp
  sourceFileName?: string
  sourceRoot?: string
}

identifier

default: { styled:'styled', createGlobal:'createGlobal' }

Used to mark the function name, compile time will lookup based on the function name to confirm if it is the target

importPaths

default: /@styils\/(react|solid)/

Used for styled or createGlobal import paths, and will only be loaded if matched

sourceFileName

default: undefined

Only needed when custom conversion, used to display the target file name

sourceRoot

default: undefined

The file path of SourceFileName

1.1.1

11 months ago

1.1.0

2 years ago

1.0.9

2 years ago

1.0.8

2 years ago

1.0.7

2 years ago

1.0.6

2 years ago

1.0.5

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago