aboutsummaryrefslogtreecommitdiffstats
path: root/vanilla/node_modules/css-tree/lib/convertor/create.js
diff options
context:
space:
mode:
Diffstat (limited to 'vanilla/node_modules/css-tree/lib/convertor/create.js')
-rw-r--r--vanilla/node_modules/css-tree/lib/convertor/create.js28
1 files changed, 0 insertions, 28 deletions
diff --git a/vanilla/node_modules/css-tree/lib/convertor/create.js b/vanilla/node_modules/css-tree/lib/convertor/create.js
deleted file mode 100644
index 56e4333..0000000
--- a/vanilla/node_modules/css-tree/lib/convertor/create.js
+++ /dev/null
@@ -1,28 +0,0 @@
-import { List } from '../utils/List.js';
-
-export function createConvertor(walk) {
- return {
- fromPlainObject(ast) {
- walk(ast, {
- enter(node) {
- if (node.children && node.children instanceof List === false) {
- node.children = new List().fromArray(node.children);
- }
- }
- });
-
- return ast;
- },
- toPlainObject(ast) {
- walk(ast, {
- leave(node) {
- if (node.children && node.children instanceof List) {
- node.children = node.children.toArray();
- }
- }
- });
-
- return ast;
- }
- };
-};