| | |
| | | /** @typedef {import("./util/runtime").RuntimeSpec} RuntimeSpec */ |
| | | |
| | | /** |
| | | * Returns wrapped source. |
| | | * @param {string} condition condition |
| | | * @param {string | Source} source source |
| | | * @returns {string | Source} wrapped source |
| | |
| | | }; |
| | | |
| | | /** |
| | | * Represents ConditionalInitFragment. |
| | | * @extends {InitFragment<GenerateContext>} |
| | | */ |
| | | class ConditionalInitFragment extends InitFragment { |
| | | /** |
| | | * Creates an instance of ConditionalInitFragment. |
| | | * @param {string | Source | undefined} content the source code that will be included as initialization code |
| | | * @param {number} stage category of initialization code (contribute to order) |
| | | * @param {number} position position in the category (contribute to order) |
| | |
| | | } |
| | | |
| | | /** |
| | | * Returns the source code that will be included as initialization code. |
| | | * @param {GenerateContext} context context |
| | | * @returns {string | Source | undefined} the source code that will be included as initialization code |
| | | */ |
| | |
| | | } |
| | | |
| | | /** |
| | | * Returns the source code that will be included at the end of the module. |
| | | * @param {GenerateContext} context context |
| | | * @returns {string | Source | undefined} the source code that will be included at the end of the module |
| | | */ |
| | |
| | | } |
| | | |
| | | /** |
| | | * Returns merged fragment. |
| | | * @param {ConditionalInitFragment} other fragment to merge with |
| | | * @returns {ConditionalInitFragment} merged fragment |
| | | */ |