source: trip-planner-front/node_modules/csso/lib/clean/index.js@ eed0bf8

Last change on this file since eed0bf8 was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 576 bytes
Line 
1var walk = require('css-tree').walk;
2var handlers = {
3 Atrule: require('./Atrule'),
4 Comment: require('./Comment'),
5 Declaration: require('./Declaration'),
6 Raw: require('./Raw'),
7 Rule: require('./Rule'),
8 TypeSelector: require('./TypeSelector'),
9 WhiteSpace: require('./WhiteSpace')
10};
11
12module.exports = function(ast, options) {
13 walk(ast, {
14 leave: function(node, item, list) {
15 if (handlers.hasOwnProperty(node.type)) {
16 handlers[node.type].call(this, node, item, list, options);
17 }
18 }
19 });
20};
Note: See TracBrowser for help on using the repository browser.