package babel
import "github.com/gohugoio/hugo/resources/resource_transformers/babel"
Index ¶
- type Client
- func New(rs *resources.Spec) *Client
- func (c *Client) Process(res resources.ResourceTransformer, options Options) (resource.Resource, error)
- type Options
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client is the client used to do Babel transformations.
func New ¶
New creates a new Client with the given specification.
func (*Client) Process ¶
func (c *Client) Process(res resources.ResourceTransformer, options Options) (resource.Resource, error)
Process transforms the given Resource with the Babel processor.
type Options ¶
type Options struct { Config string // Custom path to config file Minified bool NoComments bool Compact *bool Verbose bool NoBabelrc bool SourceMap string }
Options from https://babeljs.io/docs/en/options
func DecodeOptions ¶
DecodeOptions decodes options to and generates command flags
Source Files ¶
- Version
- v0.144.2 (latest)
- Published
- Feb 19, 2025
- Platform
- linux/amd64
- Imports
- 16 packages
- Last checked
- 12 hours ago –
Tools for package owners.