Home Reference Source
import {ProjextRollupTemplatePlugin} from 'projext-plugin-rollup/src/plugins/template/index.js'
public class | source

ProjextRollupTemplatePlugin

This is a Rollup plugin that generates an HTML file and injects a given list of scripts and stylesheets.

Constructor Summary

Public Constructor
public

Member Summary

Public Members
public

The name of the plugin's instance.

Method Summary

Public Methods
public

Gets the plugin options

public

This is called by Rollup after writing the files on the file system.

Public Constructors

public constructor(options: ProjextRollupTemplatePluginOptions, name: string) source

Params:

NameTypeAttributeDescription
options ProjextRollupTemplatePluginOptions
  • optional
  • default: {}

The options to customize the plugin behaviour.

name string
  • optional
  • default: 'projext-rollup-plugin-template'

The name of the plugin's instance.

Public Members

public name: string source

The name of the plugin's instance.

Public Methods

public getOptions(): ProjextRollupTemplatePluginOptions source

Gets the plugin options

public writeBundle() source

This is called by Rollup after writing the files on the file system. This is where the plugin parses the template and generates the HTML file.