-
Notifications
You must be signed in to change notification settings - Fork 0
/
to_deno.js
113 lines (109 loc) · 2.39 KB
/
to_deno.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
import { convert } from "https://deno.land/x/[email protected]/mod.js";
const features = [
"aac",
"border-radius",
"css-boxshadow",
"css-animation",
"css-transitions",
"transforms2d",
"transforms3d",
"css-gradients",
"css3-boxsizing",
"css-filters",
"css-filter-function",
"css-backdrop-filter",
"css-element-function",
"multicolumn",
"user-select-none",
"flexbox",
"calc",
"background-img-opts",
"background-clip-text",
"font-feature",
"font-kerning",
"border-image",
"css-selection",
"css-placeholder",
"css-placeholder-shown",
"css-hyphens",
"fullscreen",
"css3-tabsize",
"intrinsic-width",
"css3-cursors-newer",
"css3-cursors-grab",
"css-sticky",
"pointer",
"text-decoration",
"text-size-adjust",
"css-masks",
"css-clip-path",
"css-boxdecorationbreak",
"object-fit",
"css-shapes",
"text-overflow",
"css-deviceadaptation",
"css-media-resolution",
"css-text-align-last",
"css-crisp-edges",
"css-logical-props",
"css-appearance",
"css-snappoints",
"css-regions",
"css-image-set",
"css-writing-mode",
"css-cross-fade",
"css-read-only-write",
"text-emphasis",
"css-grid",
"css-text-spacing",
"css-any-link",
"css-overscroll-behavior",
"css-color-adjust",
"css-text-orientation",
"css-autofill",
"css-file-selector-button",
"css-width-stretch",
"css-print-color-adjust",
"css-featurequeries",
"mdn-text-decoration-shorthand",
"mdn-text-decoration-color",
"mdn-text-decoration-line",
"mdn-text-decoration-style",
"mdn-css-unicode-bidi-isolate",
"mdn-css-unicode-bidi-plaintext",
"mdn-css-unicode-bidi-isolate-override",
];
const download = {
"https://esm.sh/v92/[email protected]/es2022/caniuse-lite.js":
"data/caniuse-lite.js",
};
features.forEach((feature) => {
const url =
`https://esm.sh/v92/[email protected]/es2022/data/features/${feature}.js`;
const dest = `data/features/${feature}.js`;
download[url] = dest;
});
//Convert the code
await convert({
src: "autoprefixer",
input: ["lib", "data"],
output: "deno",
transpile: true,
modules: {
"": "mod.js",
"deps.js": "lib/deps.js",
"lib/utils.js": {
default: false,
},
"lib/hacks/grid-utils.js": {
default: false,
},
},
copy: {
"mod.js": "mod.js",
"deps.js": "lib/deps.js",
"test": "test",
"autoprefixer/test/cases": "test/cases",
},
download,
});