securityos/node_modules/css-tree/cjs/syntax/node/Number.cjs

26 lines
479 B
JavaScript
Raw Permalink Normal View History

2024-09-06 15:32:35 +00:00
'use strict';
const types = require('../../tokenizer/types.cjs');
const name = 'Number';
const structure = {
value: String
};
function parse() {
return {
type: 'Number',
loc: this.getLocation(this.tokenStart, this.tokenEnd),
value: this.consume(types.Number)
};
}
function generate(node) {
this.token(types.Number, node.value);
}
exports.generate = generate;
exports.name = name;
exports.parse = parse;
exports.structure = structure;