Create new
Bindings
Transitions
Animations
Easing
Component composition
Context API
Special elements
Module context
Debugging
Miscellaneous
App.svelte
runes
This component is in runes mode.
To disable runes mode, add the following to the top of your component:
<svelte:options runes={false} />
999
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
›
⌄
⌄
⌄
<script>
import { scaleLinear } from 'd3-scale';
const points = [
{ year: 1990, birthrate: 16.7 },
{ year: 1995, birthrate: 14.6 },
{ year: 2000, birthrate: 14.4 },
{ year: 2005, birthrate: 14 },
{ year: 2010, birthrate: 13 },
{ year: 2015, birthrate: 12.4 }
];
const xTicks = [1990, 1995, 2000, 2005, 2010, 2015];
const yTicks = [0, 5, 10, 15, 20];
const padding = { top: 20, right: 15, bottom: 20, left: 25 };
let width = $state(500);
let height = $state(200);
function formatMobile(tick) {
return "'" + tick.toString().slice(-2);
}
let xScale = $derived(scaleLinear()
.domain([0, xTicks.length])
.range([padding.left, width - padding.right]));
let yScale = $derived(scaleLinear()
.domain([0, Math.max.apply(null, yTicks)])
.range([height - padding.bottom, padding.top]));
let innerWidth = $derived(width - (padding.left + padding.right));
let barWidth = $derived(innerWidth / xTicks.length);
</script>
<h2>US birthrate by year</h2>
Error compiling component
WebAssembly.instantiateStreaming(): value type opcode @+13
999
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
›
⌄
⌄
⌄
⌄
import 'svelte/internal/disclose-version';
import * as $ from 'svelte/internal/client';
import { scaleLinear } from 'd3-scale';
var root_1 = $.ns_template(`<g><line x2="100%" class="svelte-1fszpww"></line><text y="-4" class="svelte-1fszpww"> </text></g>`);
var root_2 = $.ns_template(`<g class="tick svelte-1fszpww"><text y="-4" class="svelte-1fszpww"> </text></g>`);
var root_3 = $.ns_template(`<rect class="svelte-1fszpww"></rect>`);
var root = $.template(`<h2 class="svelte-1fszpww">US birthrate by year</h2> <div class="chart svelte-1fszpww"><svg class="svelte-1fszpww"><g class="axis y-axis"></g><g class="axis x-axis svelte-1fszpww"></g><g class="bars svelte-1fszpww"></g></svg></div>`, 1);
export default function App($$anchor, $$props) {
$.push($$props, true);
const points = [
{ year: 1990, birthrate: 16.7 },
{ year: 1995, birthrate: 14.6 },
{ year: 2000, birthrate: 14.4 },
{ year: 2005, birthrate: 14 },
{ year: 2010, birthrate: 13 },
{ year: 2015, birthrate: 12.4 }
];
const xTicks = [1990, 1995, 2000, 2005, 2010, 2015];
const yTicks = [0, 5, 10, 15, 20];
const padding = { top: 20, right: 15, bottom: 20, left: 25 };
let width = $.state(500);
let height = $.state(200);
function formatMobile(tick) {
return "'" + tick.toString().slice(-2);
}
let xScale = $.derived(() => scaleLinear().domain([0, xTicks.length]).range([
padding.left,
$.get(width) - padding.right
]));
result = svelte.compile(source, {
generate: ,
});99
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
›
h2.svelte-1fszpww {
text-align: center;
}
.chart.svelte-1fszpww {
width: 100%;
max-width: 500px;
margin: 0 auto;
}
svg.svelte-1fszpww {
position: relative;
width: 100%;
height: 200px;
}
.tick.svelte-1fszpww {
font-family: Helvetica, Arial;
font-size: 0.725em;
font-weight: 200;
}
.tick.svelte-1fszpww line:where(.svelte-1fszpww) {
stroke: #e2e2e2;
stroke-dasharray: 2;
}
.tick.svelte-1fszpww text:where(.svelte-1fszpww) {
fill: #ccc;
text-anchor: start;
}
.tick.tick-0.svelte-1fszpww line:where(.svelte-1fszpww) {
stroke-dasharray: 0;
}
Root {
css: StyleSheet {...}
- type: "StyleSheet"
- start: 1827
- end: 2370
- attributes: []
children: [...] (9)
Rule {...}
- type: "Rule"
prelude: SelectorList {...}
- type: "SelectorList"
- start: 1836
- end: 1838
children: [...] (1)
ComplexSelector {...}
- type: "ComplexSelector"
- start: 1836
- end: 1838
children: [...] (1)
RelativeSelector {...}
- type: "RelativeSelector"
- combinator: null
selectors: [...] (1)
TypeSelector {...}
- type: "TypeSelector"
- name: "h2"
- start: 1836
- end: 1838
}
]- start: 1836
- end: 1838
}
]
}
]
}block: Block {...}
- type: "Block"
- start: 1839
- end: 1865
children: [...] (1)
Declaration {...}
- type: "Declaration"
- start: 1843
- end: 1861
- property: "text-align"
- value: "center"
}
]
}- start: 1836
- end: 1865
} Rule {...}
- type: "Rule"
prelude: SelectorList {...}
- type: "SelectorList"
- start: 1868
- end: 1874
children: [...] (1)
ComplexSelector {...}
- type: "ComplexSelector"
- start: 1868
- end: 1874
children: [...] (1)
RelativeSelector {...}
- type: "RelativeSelector"
- combinator: null
selectors: [...] (1)
ClassSelector {...}
- type: "ClassSelector"
- name: "chart"
- start: 1868
- end: 1874
}
]- start: 1868
- end: 1874
}
]
}
]
}block: Block {...}
- type: "Block"
- start: 1875
- end: 1932
children: [...] (3)
Declaration {...}
- type: "Declaration"
- start: 1879
- end: 1890
- property: "width"
- value: "100%"
} Declaration {...}
- type: "Declaration"
- start: 1894
- end: 1910
- property: "max-width"
- value: "500px"
} Declaration {...}
- type: "Declaration"
- start: 1914
- end: 1928
- property: "margin"
- value: "0 auto"
}
]
}- start: 1868
- end: 1932
} Rule {...}
- type: "Rule"
prelude: SelectorList {...}
- type: "SelectorList"
- start: 1935
- end: 1938
children: [...] (1)
ComplexSelector {...}
- type: "ComplexSelector"
- start: 1935
- end: 1938
children: [...] (1)
RelativeSelector {...}
- type: "RelativeSelector"
- combinator: null
selectors: [...] (1)
TypeSelector {...}
- type: "TypeSelector"
- name: "svg"
- start: 1935
- end: 1938
}
]- start: 1935
- end: 1938
}
]
}
]
}block: Block {...}
- type: "Block"
- start: 1939
- end: 1997
children: [...] (3)
Declaration {...}
- type: "Declaration"
- start: 1943
- end: 1961
- property: "position"
- value: "relative"
} Declaration {...}
- type: "Declaration"
- start: 1965
- end: 1976
- property: "width"
- value: "100%"
} Declaration {...}
- type: "Declaration"
- start: 1980
- end: 1993
- property: "height"
- value: "200px"
}
]
}- start: 1935
- end: 1997
} Rule {...}
- type: "Rule"
prelude: SelectorList {...}
- type: "SelectorList"
- start: 2000
- end: 2005
children: [...] (1)
ComplexSelector {...}
- type: "ComplexSelector"
- start: 2000
- end: 2005
children: [...] (1)
RelativeSelector {...}
- type: "RelativeSelector"
- combinator: null
selectors: [...] (1)
ClassSelector {...}
- type: "ClassSelector"
- name: "tick"
- start: 2000
- end: 2005
}
]- start: 2000
- end: 2005
}
]
}
]
}block: Block {...}
- type: "Block"
- start: 2006
- end: 2085
children: [...] (3)
Declaration {...}
- type: "Declaration"
- start: 2010
- end: 2039
- property: "font-family"
- value: "Helvetica, Arial"
} Declaration {...}
- type: "Declaration"
- start: 2043
- end: 2061
- property: "font-size"
- value: "0.725em"
} Declaration {...}
- type: "Declaration"
- start: 2065
- end: 2081
- property: "font-weight"
- value: "200"
}
]
}- start: 2000
- end: 2085
} Rule {...}
- type: "Rule"
prelude: SelectorList {...}
- type: "SelectorList"
- start: 2088
- end: 2098
children: [...] (1)
ComplexSelector {...}
- type: "ComplexSelector"
- start: 2088
- end: 2098
children: [...] (2)
RelativeSelector {...}
- type: "RelativeSelector"
- combinator: null
selectors: [...] (1)
ClassSelector {...}
- type: "ClassSelector"
- name: "tick"
- start: 2088
- end: 2093
}
]- start: 2088
- end: 2093
} RelativeSelector {...}
- type: "RelativeSelector"
combinator: Combinator {...}
- type: "Combinator"
- name: " "
- start: 2093
- end: 2094
}selectors: [...] (1)
TypeSelector {...}
- type: "TypeSelector"
- name: "line"
- start: 2094
- end: 2098
}
]- start: 2093
- end: 2098
}
]
}
]
}block: Block {...}
- type: "Block"
- start: 2099
- end: 2145
children: [...] (2)
Declaration {...}
- type: "Declaration"
- start: 2103
- end: 2118
- property: "stroke"
- value: "#e2e2e2"
} Declaration {...}
- type: "Declaration"
- start: 2122
- end: 2141
- property: "stroke-dasharray"
- value: "2"
}
]
}- start: 2088
- end: 2145
} Rule {...}
- type: "Rule"
prelude: SelectorList {...}
- type: "SelectorList"
- start: 2148
- end: 2158
children: [...] (1)
ComplexSelector {...}
- type: "ComplexSelector"
- start: 2148
- end: 2158
children: [...] (2)
RelativeSelector {...}
- type: "RelativeSelector"
- combinator: null
selectors: [...] (1)
ClassSelector {...}
- type: "ClassSelector"
- name: "tick"
- start: 2148
- end: 2153
}
]- start: 2148
- end: 2153
} RelativeSelector {...}
- type: "RelativeSelector"
combinator: Combinator {...}
- type: "Combinator"
- name: " "
- start: 2153
- end: 2154
}selectors: [...] (1)
TypeSelector {...}
- type: "TypeSelector"
- name: "text"
- start: 2154
- end: 2158
}
]- start: 2153
- end: 2158
}
]
}
]
}block: Block {...}
- type: "Block"
- start: 2159
- end: 2199
children: [...] (2)
Declaration {...}
- type: "Declaration"
- start: 2163
- end: 2173
- property: "fill"
- value: "#ccc"
} Declaration {...}
- type: "Declaration"
- start: 2177
- end: 2195
- property: "text-anchor"
- value: "start"
}
]
}- start: 2148
- end: 2199
} Rule {...}
- type: "Rule"
prelude: SelectorList {...}
- type: "SelectorList"
- start: 2202
- end: 2219
children: [...] (1)
ComplexSelector {...}
- type: "ComplexSelector"
- start: 2202
- end: 2219
children: [...] (2)
RelativeSelector {...}
- type: "RelativeSelector"
- combinator: null
selectors: [...] (2)
ClassSelector {...}
- type: "ClassSelector"
- name: "tick"
- start: 2202
- end: 2207
} ClassSelector {...}
- type: "ClassSelector"
- name: "tick-0"
- start: 2207
- end: 2214
}
]- start: 2202
- end: 2214
} RelativeSelector {...}
- type: "RelativeSelector"
combinator: Combinator {...}
- type: "Combinator"
- name: " "
- start: 2214
- end: 2215
}selectors: [...] (1)
TypeSelector {...}
- type: "TypeSelector"
- name: "line"
- start: 2215
- end: 2219
}
]- start: 2214
- end: 2219
}
]
}
]
}block: Block {...}
- type: "Block"
- start: 2220
- end: 2247
children: [...] (1)
Declaration {...}
- type: "Declaration"
- start: 2224
- end: 2243
- property: "stroke-dasharray"
- value: "0"
}
]
}- start: 2202
- end: 2247
} Rule {...}
- type: "Rule"
prelude: SelectorList {...}
- type: "SelectorList"
- start: 2250
- end: 2268
children: [...] (1)
ComplexSelector {...}
- type: "ComplexSelector"
- start: 2250
- end: 2268
children: [...] (3)
RelativeSelector {...}
- type: "RelativeSelector"
- combinator: null
selectors: [...] (1)
ClassSelector {...}
- type: "ClassSelector"
- name: "x-axis"
- start: 2250
- end: 2257
}
]- start: 2250
- end: 2257
} RelativeSelector {...}
- type: "RelativeSelector"
combinator: Combinator {...}
- type: "Combinator"
- name: " "
- start: 2257
- end: 2258
}selectors: [...] (1)
ClassSelector {...}
- type: "ClassSelector"
- name: "tick"
- start: 2258
- end: 2263
}
]- start: 2257
- end: 2263
} RelativeSelector {...}
- type: "RelativeSelector"
combinator: Combinator {...}
- type: "Combinator"
- name: " "
- start: 2263
- end: 2264
}selectors: [...] (1)
TypeSelector {...}
- type: "TypeSelector"
- name: "text"
- start: 2264
- end: 2268
}
]- start: 2263
- end: 2268
}
]
}
]
}block: Block {...}
- type: "Block"
- start: 2269
- end: 2296
children: [...] (1)
Declaration {...}
- type: "Declaration"
- start: 2273
- end: 2292
- property: "text-anchor"
- value: "middle"
}
]
}- start: 2250
- end: 2296
} Rule {...}
- type: "Rule"
prelude: SelectorList {...}
- type: "SelectorList"
- start: 2299
- end: 2309
children: [...] (1)
ComplexSelector {...}
- type: "ComplexSelector"
- start: 2299
- end: 2309
children: [...] (2)
RelativeSelector {...}
- type: "RelativeSelector"
- combinator: null
selectors: [...] (1)
ClassSelector {...}
- type: "ClassSelector"
- name: "bars"
- start: 2299
- end: 2304
}
]- start: 2299
- end: 2304
} RelativeSelector {...}
- type: "RelativeSelector"
combinator: Combinator {...}
- type: "Combinator"
- name: " "
- start: 2304
- end: 2305
}selectors: [...] (1)
TypeSelector {...}
- type: "TypeSelector"
- name: "rect"
- start: 2305
- end: 2309
}
]- start: 2304
- end: 2309
}
]
}
]
}block: Block {...}
- type: "Block"
- start: 2310
- end: 2361
children: [...] (3)
Declaration {...}
- type: "Declaration"
- start: 2314
- end: 2324
- property: "fill"
- value: "#a11"
} Declaration {...}
- type: "Declaration"
- start: 2328
- end: 2340
- property: "stroke"
- value: "none"
} Declaration {...}
- type: "Declaration"
- start: 2344
- end: 2357
- property: "opacity"
- value: "0.65"
}
]
}- start: 2299
- end: 2361
}
]content: {...}
- start: 1834
- end: 2362
- styles: "\n\th2 {\n\t\ttext-align: center;\n\t}\n\n\t.chart {\n\t\twidth: 100%;\n\t\tmax-width: 500px;\n\t\tmargin: 0 auto;\n\t}\n\n\tsvg {\n\t\tposition: relative;\n\t\twidth: 100%;\n\t\theight: 200px;\n\t}\n\n\t.tick {\n\t\tfont-family: Helvetica, Arial;\n\t\tfont-size: 0.725em;\n\t\tfont-weight: 200;\n\t}\n\n\t.tick line {\n\t\tstroke: #e2e2e2;\n\t\tstroke-dasharray: 2;\n\t}\n\n\t.tick text {\n\t\tfill: #ccc;\n\t\ttext-anchor: start;\n\t}\n\n\t.tick.tick-0 line {\n\t\tstroke-dasharray: 0;\n\t}\n\n\t.x-axis .tick text {\n\t\ttext-anchor: middle;\n\t}\n\n\t.bars rect {\n\t\tfill: #a11;\n\t\tstroke: none;\n\t\topacity: 0.65;\n\t}\n"
- comment: null
}
}- js: []
- start: 949
- end: 1825
- type: "Root"
fragment: Fragment {...}
- type: "Fragment"
nodes: [...] (5)
Text {...}
- type: "Text"
- start: 947
- end: 949
- raw: "\n\n"
- data: "\n\n"
} RegularElement {...}
- type: "RegularElement"
- start: 949
- end: 978
- name: "h2"
attributes: [...] (1)
Attribute {...}
- type: "Attribute"
- start: -1
- end: -1
- name: "class"
value: [...] (1)
Text {...}
- type: "Text"
- data: "svelte-1fszpww"
- raw: "svelte-1fszpww"
- start: -1
- end: -1
}
]
}
]fragment: Fragment {...}
- type: "Fragment"
nodes: [...] (1)
Text {...}
- type: "Text"
- start: 953
- end: 973
- raw: "US birthrate by year"
- data: "US birthrate by year"
}
]
}
} Text {...}
- type: "Text"
- start: 978
- end: 980
- raw: " "
- data: " "
} RegularElement {...}
- type: "RegularElement"
- start: 980
- end: 1825
- name: "div"
attributes: [...] (3)
Attribute {...}
- type: "Attribute"
- start: 985
- end: 998
- name: "class"
value: [...] (1)
Text {...}
- start: 992
- end: 997
- type: "Text"
- raw: "chart"
- data: "chart svelte-1fszpww"
}
]
} BindDirective {...}
- start: 999
- end: 1023
- type: "BindDirective"
- name: "clientWidth"
expression: Identifier {...}
- type: "Identifier"
- start: 1017
- end: 1022
loc: {...}
start: {...}
- line: 38
- column: 37
}end: {...}
- line: 38
- column: 42
}
}- name: "width"
}- modifiers: []
} BindDirective {...}
- start: 1024
- end: 1050
- type: "BindDirective"
- name: "clientHeight"
expression: Identifier {...}
- type: "Identifier"
- start: 1043
- end: 1049
loc: {...}
start: {...}
- line: 38
- column: 63
}end: {...}
- line: 38
- column: 69
}
}- name: "height"
}- modifiers: []
}
]fragment: Fragment {...}
- type: "Fragment"
nodes: [...] (3)
Text {...}
- type: "Text"
- start: 1051
- end: 1053
- raw: "\n\t"
- data: "\n\t"
} RegularElement {...}
- type: "RegularElement"
- start: 1053
- end: 1818
- name: "svg"
attributes: [...] (1)
Attribute {...}
- type: "Attribute"
- start: -1
- end: -1
- name: "class"
value: [...] (1)
Text {...}
- type: "Text"
- data: "svelte-1fszpww"
- raw: "svelte-1fszpww"
- start: -1
- end: -1
}
]
}
]fragment: Fragment {...}
- type: "Fragment"
nodes: [...] (11)
Text {...}
- type: "Text"
- start: 1058
- end: 1061
- raw: "\n\t\t"
- data: "\n\t\t"
} Comment {...}
- type: "Comment"
- start: 1061
- end: 1076
- data: " y axis "
} Text {...}
- type: "Text"
- start: 1076
- end: 1079
- raw: "\n\t\t"
- data: "\n\t\t"
} RegularElement {...}
- type: "RegularElement"
- start: 1079
- end: 1330
- name: "g"
attributes: [...] (1)
Attribute {...}
- type: "Attribute"
- start: 1082
- end: 1101
- name: "class"
value: [...] (1)
Text {...}
- start: 1089
- end: 1100
- type: "Text"
- raw: "axis y-axis"
- data: "axis y-axis"
}
]
}
]fragment: Fragment {...}
- type: "Fragment"
nodes: [...] (3)
Text {...}
- type: "Text"
- start: 1102
- end: 1106
- raw: "\n\t\t\t"
- data: "\n\t\t\t"
} EachBlock {...}
- type: "EachBlock"
- start: 1106
- end: 1323
expression: Identifier {...}
- type: "Identifier"
- start: 1113
- end: 1119
loc: {...}
start: {...}
- line: 42
- column: 10
}end: {...}
- line: 42
- column: 16
}
}- name: "yTicks"
}body: Fragment {...}
- type: "Fragment"
nodes: [...] (3)
Text {...}
- type: "Text"
- start: 1128
- end: 1133
- raw: "\n\t\t\t\t"
- data: "\n\t\t\t\t"
} RegularElement {...}
- type: "RegularElement"
- start: 1133
- end: 1312
- name: "g"
attributes: [...] (2)
Attribute {...}
- type: "Attribute"
- start: 1136
- end: 1160
- name: "class"
value: [...] (3)
Text {...}
- start: 1143
- end: 1153
- type: "Text"
- raw: "tick tick-"
- data: "tick tick-"
} ExpressionTag {...}
- type: "ExpressionTag"
- start: 1153
- end: 1159
expression: Identifier {...}
- type: "Identifier"
- start: 1154
- end: 1158
loc: {...}
start: {...}
- line: 43
- column: 25
}end: {...}
- line: 43
- column: 29
}
}- name: "tick"
}
} Text {...}
- type: "Text"
- data: " svelte-1fszpww"
- raw: " svelte-1fszpww"
- start: -1
- end: -1
}
]
} Attribute {...}
- type: "Attribute"
- start: 1161
- end: 1201
- name: "transform"
value: [...] (3)
Text {...}
- start: 1172
- end: 1185
- type: "Text"
- raw: "translate(0, "
- data: "translate(0, "
} ExpressionTag {...}
- type: "ExpressionTag"
- start: 1185
- end: 1199
expression: CallExpression {...}
- type: "CallExpression"
- start: 1186
- end: 1198
loc: {...}
start: {...}
- line: 43
- column: 57
}end: {...}
- line: 43
- column: 69
}
}callee: Identifier {...}
- type: "Identifier"
- start: 1186
- end: 1192
loc: {...}
start: {...}
- line: 43
- column: 57
}end: {...}
- line: 43
- column: 63
}
}- name: "yScale"
}arguments: [...] (1)
Identifier {...}
- type: "Identifier"
- start: 1193
- end: 1197
loc: {...}
start: {...}
- line: 43
- column: 64
}end: {...}
- line: 43
- column: 68
}
}- name: "tick"
}
]- optional: false
}
} Text {...}
- start: 1199
- end: 1200
- type: "Text"
- raw: ")"
- data: ")"
}
]
}
]fragment: Fragment {...}
- type: "Fragment"
nodes: [...] (5)
Text {...}
- type: "Text"
- start: 1202
- end: 1208
- raw: "\n\t\t\t\t\t"
- data: "\n\t\t\t\t\t"
} RegularElement {...}
- type: "RegularElement"
- start: 1208
- end: 1226
- name: "line"
attributes: [...] (2)
Attribute {...}
- type: "Attribute"
- start: 1214
- end: 1223
- name: "x2"
value: [...] (1)
Text {...}
- start: 1218
- end: 1222
- type: "Text"
- raw: "100%"
- data: "100%"
}
]
} Attribute {...}
- type: "Attribute"
- start: -1
- end: -1
- name: "class"
value: [...] (1)
Text {...}
- type: "Text"
- data: "svelte-1fszpww"
- raw: "svelte-1fszpww"
- start: -1
- end: -1
}
]
}
]fragment: Fragment {...}
- type: "Fragment"
- nodes: []
}
} Text {...}
- type: "Text"
- start: 1226
- end: 1232
- raw: " "
- data: " "
} RegularElement {...}
- type: "RegularElement"
- start: 1232
- end: 1303
- name: "text"
attributes: [...] (2)
Attribute {...}
- type: "Attribute"
- start: 1238
- end: 1244
- name: "y"
value: [...] (1)
Text {...}
- start: 1241
- end: 1243
- type: "Text"
- raw: "-4"
- data: "-4"
}
]
} Attribute {...}
- type: "Attribute"
- start: -1
- end: -1
- name: "class"
value: [...] (1)
Text {...}
- type: "Text"
- data: "svelte-1fszpww"
- raw: "svelte-1fszpww"
- start: -1
- end: -1
}
]
}
]fragment: Fragment {...}
- type: "Fragment"
nodes: [...] (3)
ExpressionTag {...}
- type: "ExpressionTag"
- start: 1245
- end: 1251
expression: Identifier {...}
- type: "Identifier"
- start: 1246
- end: 1250
loc: {...}
start: {...}
- line: 45
- column: 19
}end: {...}
- line: 45
- column: 23
}
}- name: "tick"
}
} Text {...}
- type: "Text"
- start: 1251
- end: 1252
- raw: " "
- data: " "
} ExpressionTag {...}
- type: "ExpressionTag"
- start: 1252
- end: 1296
expression: ConditionalExpression {...}
- type: "ConditionalExpression"
- start: 1253
- end: 1295
loc: {...}
start: {...}
- line: 45
- column: 26
}end: {...}
- line: 45
- column: 68
}
}test: BinaryExpression {...}
- type: "BinaryExpression"
- start: 1253
- end: 1264
loc: {...}
start: {...}
- line: 45
- column: 26
}end: {...}
- line: 45
- column: 37
}
}left: Identifier {...}
- type: "Identifier"
- start: 1253
- end: 1257
loc: {...}
start: {...}
- line: 45
- column: 26
}end: {...}
- line: 45
- column: 30
}
}- name: "tick"
}- operator: "==="
right: Literal {...}
- type: "Literal"
- start: 1262
- end: 1264
loc: {...}
start: {...}
- line: 45
- column: 35
}end: {...}
- line: 45
- column: 37
}
}- value: 20
- raw: "20"
}
}consequent: Literal {...}
- type: "Literal"
- start: 1267
- end: 1290
loc: {...}
start: {...}
- line: 45
- column: 40
}end: {...}
- line: 45
- column: 63
}
}- value: " per 1,000 population"
- raw: "' per 1,000 population'"
}alternate: Literal {...}
- type: "Literal"
- start: 1293
- end: 1295
loc: {...}
start: {...}
- line: 45
- column: 66
}end: {...}
- line: 45
- column: 68
}
}- value: ""
- raw: "''"
}
}
}
]
}
} Text {...}
- type: "Text"
- start: 1303
- end: 1308
- raw: "\n\t\t\t\t"
- data: "\n\t\t\t\t"
}
]
}
} Text {...}
- type: "Text"
- start: 1312
- end: 1316
- raw: "\n\t\t\t"
- data: "\n\t\t\t"
}
]
}context: Identifier {...}
- type: "Identifier"
- name: "tick"
- start: 1123
loc: {...}
start: {...}
- line: 42
- column: 20
- character: 1123
}end: {...}
- line: 42
- column: 24
- character: 1127
}
}- end: 1127
- typeAnnotation: undefined
}- index: undefined
- key: undefined
} Text {...}
- type: "Text"
- start: 1323
- end: 1326
- raw: "\n\t\t"
- data: "\n\t\t"
}
]
}
} Text {...}
- type: "Text"
- start: 1330
- end: 1334
- raw: " "
- data: " "
} Comment {...}
- type: "Comment"
- start: 1334
- end: 1349
- data: " x axis "
} Text {...}
- type: "Text"
- start: 1349
- end: 1352
- raw: ""
- data: ""
} RegularElement {...}
- type: "RegularElement"
- start: 1352
- end: 1593
- name: "g"
attributes: [...] (1)
Attribute {...}
- type: "Attribute"
- start: 1355
- end: 1374
- name: "class"
value: [...] (1)
Text {...}
- start: 1362
- end: 1373
- type: "Text"
- raw: "axis x-axis"
- data: "axis x-axis svelte-1fszpww"
}
]
}
]fragment: Fragment {...}
- type: "Fragment"
nodes: [...] (3)
Text {...}
- type: "Text"
- start: 1375
- end: 1379
- raw: "\n\t\t\t"
- data: "\n\t\t\t"
} EachBlock {...}
- type: "EachBlock"
- start: 1379
- end: 1586
expression: Identifier {...}
- type: "Identifier"
- start: 1386
- end: 1392
loc: {...}
start: {...}
- line: 52
- column: 10
}end: {...}
- line: 52
- column: 16
}
}- name: "points"
}body: Fragment {...}
- type: "Fragment"
nodes: [...] (3)
Text {...}
- type: "Text"
- start: 1405
- end: 1410
- raw: "\n\t\t\t\t"
- data: "\n\t\t\t\t"
} RegularElement {...}
- type: "RegularElement"
- start: 1410
- end: 1575
- name: "g"
attributes: [...] (2)
Attribute {...}
- type: "Attribute"
- start: 1413
- end: 1425
- name: "class"
value: [...] (1)
Text {...}
- start: 1420
- end: 1424
- type: "Text"
- raw: "tick"
- data: "tick svelte-1fszpww"
}
]
} Attribute {...}
- type: "Attribute"
- start: 1426
- end: 1469
- name: "transform"
value: [...] (5)
Text {...}
- start: 1437
- end: 1447
- type: "Text"
- raw: "translate("
- data: "translate("
} ExpressionTag {...}
- type: "ExpressionTag"
- start: 1447
- end: 1458
expression: CallExpression {...}
- type: "CallExpression"
- start: 1448
- end: 1457
loc: {...}
start: {...}
- line: 53
- column: 42
}end: {...}
- line: 53
- column: 51
}
}callee: Identifier {...}
- type: "Identifier"
- start: 1448
- end: 1454
loc: {...}
start: {...}
- line: 53
- column: 42
}end: {...}
- line: 53
- column: 48
}
}- name: "xScale"
}arguments: [...] (1)
Identifier {...}
- type: "Identifier"
- start: 1455
- end: 1456
loc: {...}
start: {...}
- line: 53
- column: 49
}end: {...}
- line: 53
- column: 50
}
}- name: "i"
}
]- optional: false
}
} Text {...}
- start: 1458
- end: 1459
- type: "Text"
- raw: ","
- data: ","
} ExpressionTag {...}
- type: "ExpressionTag"
- start: 1459
- end: 1467
expression: Identifier {...}
- type: "Identifier"
- start: 1460
- end: 1466
loc: {...}
start: {...}
- line: 53
- column: 54
}end: {...}
- line: 53
- column: 60
}
}- name: "height"
}
} Text {...}
- start: 1467
- end: 1468
- type: "Text"
- raw: ")"
- data: ")"
}
]
}
]fragment: Fragment {...}
- type: "Fragment"
nodes: [...] (3)
Text {...}
- type: "Text"
- start: 1470
- end: 1476
- raw: "\n\t\t\t\t\t"
- data: "\n\t\t\t\t\t"
} RegularElement {...}
- type: "RegularElement"
- start: 1476
- end: 1566
- name: "text"
attributes: [...] (3)
Attribute {...}
- type: "Attribute"
- start: 1482
- end: 1498
- name: "x"
value: ExpressionTag {...}
- type: "ExpressionTag"
- start: 1484
- end: 1498
expression: BinaryExpression {...}
- type: "BinaryExpression"
- start: 1485
- end: 1497
loc: {...}
start: {...}
- line: 54
- column: 14
}end: {...}
- line: 54
- column: 26
}
}left: Identifier {...}
- type: "Identifier"
- start: 1485
- end: 1493
loc: {...}
start: {...}
- line: 54
- column: 14
}end: {...}
- line: 54
- column: 22
}
}- name: "barWidth"
}- operator: "/"
right: Literal {...}
- type: "Literal"
- start: 1496
- end: 1497
loc: {...}
start: {...}
- line: 54
- column: 25
}end: {...}
- line: 54
- column: 26
}
}- value: 2
- raw: "2"
}
}
}
} Attribute {...}
- type: "Attribute"
- start: 1499
- end: 1505
- name: "y"
value: [...] (1)
Text {...}
- start: 1502
- end: 1504
- type: "Text"
- raw: "-4"
- data: "-4"
}
]
} Attribute {...}
- type: "Attribute"
- start: -1
- end: -1
- name: "class"
value: [...] (1)
Text {...}
- type: "Text"
- data: "svelte-1fszpww"
- raw: "svelte-1fszpww"
- start: -1
- end: -1
}
]
}
]fragment: Fragment {...}
- type: "Fragment"
nodes: [...] (1)
ExpressionTag {...}
- type: "ExpressionTag"
- start: 1506
- end: 1559
expression: ConditionalExpression {...}
- type: "ConditionalExpression"
- start: 1507
- end: 1558
loc: {...}
start: {...}
- line: 54
- column: 36
}end: {...}
- line: 54
- column: 87
}
}test: BinaryExpression {...}
- type: "BinaryExpression"
- start: 1507
- end: 1518
loc: {...}
start: {...}
- line: 54
- column: 36
}end: {...}
- line: 54
- column: 47
}
}left: Identifier {...}
- type: "Identifier"
- start: 1507
- end: 1512
loc: {...}
start: {...}
- line: 54
- column: 36
}end: {...}
- line: 54
- column: 41
}
}- name: "width"
}- operator: ">"
right: Literal {...}
- type: "Literal"
- start: 1515
- end: 1518
loc: {...}
start: {...}
- line: 54
- column: 44
}end: {...}
- line: 54
- column: 47
}
}- value: 380
- raw: "380"
}
}consequent: MemberExpression {...}
- type: "MemberExpression"
- start: 1521
- end: 1531
loc: {...}
start: {...}
- line: 54
- column: 50
}end: {...}
- line: 54
- column: 60
}
}object: Identifier {...}
- type: "Identifier"
- start: 1521
- end: 1526
loc: {...}
start: {...}
- line: 54
- column: 50
}end: {...}
- line: 54
- column: 55
}
}- name: "point"
}property: Identifier {...}
- type: "Identifier"
- start: 1527
- end: 1531
loc: {...}
start: {...}
- line: 54
- column: 56
}end: {...}
- line: 54
- column: 60
}
}- name: "year"
}- computed: false
- optional: false
}alternate: CallExpression {...}
- type: "CallExpression"
- start: 1534
- end: 1558
loc: {...}
start: {...}
- line: 54
- column: 63
}end: {...}
- line: 54
- column: 87
}
}callee: Identifier {...}
- type: "Identifier"
- start: 1534
- end: 1546
loc: {...}
start: {...}
- line: 54
- column: 63
}end: {...}
- line: 54
- column: 75
}
}- name: "formatMobile"
}arguments: [...] (1)
MemberExpression {...}
- type: "MemberExpression"
- start: 1547
- end: 1557
loc: {...}
start: {...}
- line: 54
- column: 76
}end: {...}
- line: 54
- column: 86
}
}object: Identifier {...}
- type: "Identifier"
- start: 1547
- end: 1552
loc: {...}
start: {...}
- line: 54
- column: 76
}end: {...}
- line: 54
- column: 81
}
}- name: "point"
}property: Identifier {...}
- type: "Identifier"
- start: 1553
- end: 1557
loc: {...}
start: {...}
- line: 54
- column: 82
}end: {...}
- line: 54
- column: 86
}
}- name: "year"
}- computed: false
- optional: false
}
]- optional: false
}
}
}
]
}
} Text {...}
- type: "Text"
- start: 1566
- end: 1571
- raw: "\n\t\t\t\t"
- data: "\n\t\t\t\t"
}
]
}
} Text {...}
- type: "Text"
- start: 1575
- end: 1579
- raw: "\n\t\t\t"
- data: "\n\t\t\t"
}
]
}context: Identifier {...}
- type: "Identifier"
- name: "point"
- start: 1396
loc: {...}
start: {...}
- line: 52
- column: 20
- character: 1396
}end: {...}
- line: 52
- column: 25
- character: 1401
}
}- end: 1401
- typeAnnotation: undefined
}- index: "i"
- key: undefined
} Text {...}
- type: "Text"
- start: 1586
- end: 1589
- raw: "\n\t\t"
- data: "\n\t\t"
}
]
}
} Text {...}
- type: "Text"
- start: 1593
- end: 1597
- raw: " "
- data: " "
} RegularElement {...}
- type: "RegularElement"
- start: 1597
- end: 1810
- name: "g"
attributes: [...] (1)
Attribute {...}
- type: "Attribute"
- start: 1600
- end: 1612
- name: "class"
value: [...] (1)
Text {...}
- start: 1607
- end: 1611
- type: "Text"
- raw: "bars"
- data: "bars svelte-1fszpww"
}
]
}
]fragment: Fragment {...}
- type: "Fragment"
nodes: [...] (3)
Text {...}
- type: "Text"
- start: 1613
- end: 1617
- raw: "\n\t\t\t"
- data: "\n\t\t\t"
} EachBlock {...}
- type: "EachBlock"
- start: 1617
- end: 1803
expression: Identifier {...}
- type: "Identifier"
- start: 1624
- end: 1630
loc: {...}
start: {...}
- line: 60
- column: 10
}end: {...}
- line: 60
- column: 16
}
}- name: "points"
}body: Fragment {...}
- type: "Fragment"
nodes: [...] (3)
Text {...}
- type: "Text"
- start: 1643
- end: 1648
- raw: "\n\t\t\t\t"
- data: "\n\t\t\t\t"
} RegularElement {...}
- type: "RegularElement"
- start: 1648
- end: 1792
- name: "rect"
attributes: [...] (5)
Attribute {...}
- type: "Attribute"
- start: 1659
- end: 1676
- name: "x"
value: ExpressionTag {...}
- type: "ExpressionTag"
- start: 1661
- end: 1676
expression: BinaryExpression {...}
- type: "BinaryExpression"
- start: 1662
- end: 1675
loc: {...}
start: {...}
- line: 62
- column: 8
}end: {...}
- line: 62
- column: 21
}
}left: CallExpression {...}
- type: "CallExpression"
- start: 1662
- end: 1671
loc: {...}
start: {...}
- line: 62
- column: 8
}end: {...}
- line: 62
- column: 17
}
}callee: Identifier {...}
- type: "Identifier"
- start: 1662
- end: 1668
loc: {...}
start: {...}
- line: 62
- column: 8
}end: {...}
- line: 62
- column: 14
}
}- name: "xScale"
}arguments: [...] (1)
Identifier {...}
- type: "Identifier"
- start: 1669
- end: 1670
loc: {...}
start: {...}
- line: 62
- column: 15
}end: {...}
- line: 62
- column: 16
}
}- name: "i"
}
]- optional: false
}- operator: "+"
right: Literal {...}
- type: "Literal"
- start: 1674
- end: 1675
loc: {...}
start: {...}
- line: 62
- column: 20
}end: {...}
- line: 62
- column: 21
}
}- value: 2
- raw: "2"
}
}
}
} Attribute {...}
- type: "Attribute"
- start: 1682
- end: 1709
- name: "y"
value: ExpressionTag {...}
- type: "ExpressionTag"
- start: 1684
- end: 1709
expression: CallExpression {...}
- type: "CallExpression"
- start: 1685
- end: 1708
loc: {...}
start: {...}
- line: 63
- column: 8
}end: {...}
- line: 63
- column: 31
}
}callee: Identifier {...}
- type: "Identifier"
- start: 1685
- end: 1691
loc: {...}
start: {...}
- line: 63
- column: 8
}end: {...}
- line: 63
- column: 14
}
}- name: "yScale"
}arguments: [...] (1)
MemberExpression {...}
- type: "MemberExpression"
- start: 1692
- end: 1707
loc: {...}
start: {...}
- line: 63
- column: 15
}end: {...}
- line: 63
- column: 30
}
}object: Identifier {...}
- type: "Identifier"
- start: 1692
- end: 1697
loc: {...}
start: {...}
- line: 63
- column: 15
}end: {...}
- line: 63
- column: 20
}
}- name: "point"
}property: Identifier {...}
- type: "Identifier"
- start: 1698
- end: 1707
loc: {...}
start: {...}
- line: 63
- column: 21
}end: {...}
- line: 63
- column: 30
}
}- name: "birthrate"
}- computed: false
- optional: false
}
]- optional: false
}
}
} Attribute {...}
- type: "Attribute"
- start: 1715
- end: 1735
- name: "width"
value: ExpressionTag {...}
- type: "ExpressionTag"
- start: 1721
- end: 1735
expression: BinaryExpression {...}
- type: "BinaryExpression"
- start: 1722
- end: 1734
loc: {...}
start: {...}
- line: 64
- column: 12
}end: {...}
- line: 64
- column: 24
}
}left: Identifier {...}
- type: "Identifier"
- start: 1722
- end: 1730
loc: {...}
start: {...}
- line: 64
- column: 12
}end: {...}
- line: 64
- column: 20
}
}- name: "barWidth"
}- operator: "-"
right: Literal {...}
- type: "Literal"
- start: 1733
- end: 1734
loc: {...}
start: {...}
- line: 64
- column: 23
}end: {...}
- line: 64
- column: 24
}
}- value: 4
- raw: "4"
}
}
}
} Attribute {...}
- type: "Attribute"
- start: 1741
- end: 1785
- name: "height"
value: ExpressionTag {...}
- type: "ExpressionTag"
- start: 1748
- end: 1785
expression: BinaryExpression {...}
- type: "BinaryExpression"
- start: 1749
- end: 1784
loc: {...}
start: {...}
- line: 65
- column: 13
}end: {...}
- line: 65
- column: 48
}
}left: CallExpression {...}
- type: "CallExpression"
- start: 1749
- end: 1758
loc: {...}
start: {...}
- line: 65
- column: 13
}end: {...}
- line: 65
- column: 22
}
}callee: Identifier {...}
- type: "Identifier"
- start: 1749
- end: 1755
loc: {...}
start: {...}
- line: 65
- column: 13
}end: {...}
- line: 65
- column: 19
}
}- name: "yScale"
}arguments: [...] (1)
Literal {...}
- type: "Literal"
- start: 1756
- end: 1757
loc: {...}
start: {...}
- line: 65
- column: 20
}end: {...}
- line: 65
- column: 21
}
}- value: 0
- raw: "0"
}
]- optional: false
}- operator: "-"
right: CallExpression {...}
- type: "CallExpression"
- start: 1761
- end: 1784
loc: {...}
start: {...}
- line: 65
- column: 25
}end: {...}
- line: 65
- column: 48
}
}callee: Identifier {...}
- type: "Identifier"
- start: 1761
- end: 1767
loc: {...}
start: {...}
- line: 65
- column: 25
}end: {...}
- line: 65
- column: 31
}
}- name: "yScale"
}arguments: [...] (1)
MemberExpression {...}
- type: "MemberExpression"
- start: 1768
- end: 1783
loc: {...}
start: {...}
- line: 65
- column: 32
}end: {...}
- line: 65
- column: 47
}
}object: Identifier {...}
- type: "Identifier"
- start: 1768
- end: 1773
loc: {...}
start: {...}
- line: 65
- column: 32
}end: {...}
- line: 65
- column: 37
}
}- name: "point"
}property: Identifier {...}
- type: "Identifier"
- start: 1774
- end: 1783
loc: {...}
start: {...}
- line: 65
- column: 38
}end: {...}
- line: 65
- column: 47
}
}- name: "birthrate"
}- computed: false
- optional: false
}
]- optional: false
}
}
}
} Attribute {...}
- type: "Attribute"
- start: -1
- end: -1
- name: "class"
value: [...] (1)
Text {...}
- type: "Text"
- data: "svelte-1fszpww"
- raw: "svelte-1fszpww"
- start: -1
- end: -1
}
]
}
]fragment: Fragment {...}
- type: "Fragment"
- nodes: []
}
} Text {...}
- type: "Text"
- start: 1792
- end: 1796
- raw: "\n\t\t\t"
- data: "\n\t\t\t"
}
]
}context: Identifier {...}
- type: "Identifier"
- name: "point"
- start: 1634
loc: {...}
start: {...}
- line: 60
- column: 20
- character: 1634
}end: {...}
- line: 60
- column: 25
- character: 1639
}
}- end: 1639
- typeAnnotation: undefined
}- index: "i"
- key: undefined
} Text {...}
- type: "Text"
- start: 1803
- end: 1806
- raw: "\n\t\t"
- data: "\n\t\t"
}
]
}
} Text {...}
- type: "Text"
- start: 1810
- end: 1812
- raw: "\n\t"
- data: "\n\t"
}
]
}
} Text {...}
- type: "Text"
- start: 1818
- end: 1819
- raw: "\n"
- data: "\n"
}
]
}
} Text {...}
- type: "Text"
- start: 1825
- end: 1827
- raw: "\n\n"
- data: "\n\n"
}
]
}- options: null
instance: Script {...}
- type: "Script"
- start: 0
- end: 947
- context: "default"
content: Program {...}
- type: "Program"
- start: 8
- end: 938
loc: {...}
start: {...}
- line: 1
- column: 0
}end: {...}
- line: 34
- column: 0
}
}body: [...] (12)
ImportDeclaration {...}
- type: "ImportDeclaration"
- start: 10
- end: 49
loc: {...}
start: {...}
- line: 2
- column: 1
}end: {...}
- line: 2
- column: 40
}
}specifiers: [...] (1)
ImportSpecifier {...}
- type: "ImportSpecifier"
- start: 19
- end: 30
loc: {...}
start: {...}
- line: 2
- column: 10
}end: {...}
- line: 2
- column: 21
}
}imported: Identifier {...}
- type: "Identifier"
- start: 19
- end: 30
loc: {...}
start: {...}
- line: 2
- column: 10
}end: {...}
- line: 2
- column: 21
}
}- name: "scaleLinear"
}local: Identifier {...}
- type: "Identifier"
- start: 19
- end: 30
loc: {...}
start: {...}
- line: 2
- column: 10
}end: {...}
- line: 2
- column: 21
}
}- name: "scaleLinear"
}
}
]source: Literal {...}
- type: "Literal"
- start: 38
- end: 48
loc: {...}
start: {...}
- line: 2
- column: 29
}end: {...}
- line: 2
- column: 39
}
}- value: "d3-scale"
- raw: "'d3-scale'"
}
} VariableDeclaration {...}
- type: "VariableDeclaration"
- start: 52
- end: 277
loc: {...}
start: {...}
- line: 4
- column: 1
}end: {...}
- line: 11
- column: 3
}
}declarations: [...] (1)
VariableDeclarator {...}
- type: "VariableDeclarator"
- start: 58
- end: 276
loc: {...}
start: {...}
- line: 4
- column: 7
}end: {...}
- line: 11
- column: 2
}
}id: Identifier {...}
- type: "Identifier"
- start: 58
- end: 64
loc: {...}
start: {...}
- line: 4
- column: 7
}end: {...}
- line: 4
- column: 13
}
}- name: "points"
}init: ArrayExpression {...}
- type: "ArrayExpression"
- start: 67
- end: 276
loc: {...}
start: {...}
- line: 4
- column: 16
}end: {...}
- line: 11
- column: 2
}
}elements: [...] (6)
ObjectExpression {...}
- type: "ObjectExpression"
- start: 71
- end: 102
loc: {...}
start: {...}
- line: 5
- column: 2
}end: {...}
- line: 5
- column: 33
}
}properties: [...] (2)
Property {...}
- type: "Property"
- start: 73
- end: 83
loc: {...}
start: {...}
- line: 5
- column: 4
}end: {...}
- line: 5
- column: 14
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 73
- end: 77
loc: {...}
start: {...}
- line: 5
- column: 4
}end: {...}
- line: 5
- column: 8
}
}- name: "year"
}value: Literal {...}
- type: "Literal"
- start: 79
- end: 83
loc: {...}
start: {...}
- line: 5
- column: 10
}end: {...}
- line: 5
- column: 14
}
}- value: 1990
- raw: "1990"
}- kind: "init"
} Property {...}
- type: "Property"
- start: 85
- end: 100
loc: {...}
start: {...}
- line: 5
- column: 16
}end: {...}
- line: 5
- column: 31
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 85
- end: 94
loc: {...}
start: {...}
- line: 5
- column: 16
}end: {...}
- line: 5
- column: 25
}
}- name: "birthrate"
}value: Literal {...}
- type: "Literal"
- start: 96
- end: 100
loc: {...}
start: {...}
- line: 5
- column: 27
}end: {...}
- line: 5
- column: 31
}
}- value: 16.7
- raw: "16.7"
}- kind: "init"
}
]
} ObjectExpression {...}
- type: "ObjectExpression"
- start: 106
- end: 137
loc: {...}
start: {...}
- line: 6
- column: 2
}end: {...}
- line: 6
- column: 33
}
}properties: [...] (2)
Property {...}
- type: "Property"
- start: 108
- end: 118
loc: {...}
start: {...}
- line: 6
- column: 4
}end: {...}
- line: 6
- column: 14
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 108
- end: 112
loc: {...}
start: {...}
- line: 6
- column: 4
}end: {...}
- line: 6
- column: 8
}
}- name: "year"
}value: Literal {...}
- type: "Literal"
- start: 114
- end: 118
loc: {...}
start: {...}
- line: 6
- column: 10
}end: {...}
- line: 6
- column: 14
}
}- value: 1995
- raw: "1995"
}- kind: "init"
} Property {...}
- type: "Property"
- start: 120
- end: 135
loc: {...}
start: {...}
- line: 6
- column: 16
}end: {...}
- line: 6
- column: 31
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 120
- end: 129
loc: {...}
start: {...}
- line: 6
- column: 16
}end: {...}
- line: 6
- column: 25
}
}- name: "birthrate"
}value: Literal {...}
- type: "Literal"
- start: 131
- end: 135
loc: {...}
start: {...}
- line: 6
- column: 27
}end: {...}
- line: 6
- column: 31
}
}- value: 14.6
- raw: "14.6"
}- kind: "init"
}
]
} ObjectExpression {...}
- type: "ObjectExpression"
- start: 141
- end: 172
loc: {...}
start: {...}
- line: 7
- column: 2
}end: {...}
- line: 7
- column: 33
}
}properties: [...] (2)
Property {...}
- type: "Property"
- start: 143
- end: 153
loc: {...}
start: {...}
- line: 7
- column: 4
}end: {...}
- line: 7
- column: 14
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 143
- end: 147
loc: {...}
start: {...}
- line: 7
- column: 4
}end: {...}
- line: 7
- column: 8
}
}- name: "year"
}value: Literal {...}
- type: "Literal"
- start: 149
- end: 153
loc: {...}
start: {...}
- line: 7
- column: 10
}end: {...}
- line: 7
- column: 14
}
}- value: 2000
- raw: "2000"
}- kind: "init"
} Property {...}
- type: "Property"
- start: 155
- end: 170
loc: {...}
start: {...}
- line: 7
- column: 16
}end: {...}
- line: 7
- column: 31
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 155
- end: 164
loc: {...}
start: {...}
- line: 7
- column: 16
}end: {...}
- line: 7
- column: 25
}
}- name: "birthrate"
}value: Literal {...}
- type: "Literal"
- start: 166
- end: 170
loc: {...}
start: {...}
- line: 7
- column: 27
}end: {...}
- line: 7
- column: 31
}
}- value: 14.4
- raw: "14.4"
}- kind: "init"
}
]
} ObjectExpression {...}
- type: "ObjectExpression"
- start: 176
- end: 205
loc: {...}
start: {...}
- line: 8
- column: 2
}end: {...}
- line: 8
- column: 31
}
}properties: [...] (2)
Property {...}
- type: "Property"
- start: 178
- end: 188
loc: {...}
start: {...}
- line: 8
- column: 4
}end: {...}
- line: 8
- column: 14
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 178
- end: 182
loc: {...}
start: {...}
- line: 8
- column: 4
}end: {...}
- line: 8
- column: 8
}
}- name: "year"
}value: Literal {...}
- type: "Literal"
- start: 184
- end: 188
loc: {...}
start: {...}
- line: 8
- column: 10
}end: {...}
- line: 8
- column: 14
}
}- value: 2005
- raw: "2005"
}- kind: "init"
} Property {...}
- type: "Property"
- start: 190
- end: 203
loc: {...}
start: {...}
- line: 8
- column: 16
}end: {...}
- line: 8
- column: 29
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 190
- end: 199
loc: {...}
start: {...}
- line: 8
- column: 16
}end: {...}
- line: 8
- column: 25
}
}- name: "birthrate"
}value: Literal {...}
- type: "Literal"
- start: 201
- end: 203
loc: {...}
start: {...}
- line: 8
- column: 27
}end: {...}
- line: 8
- column: 29
}
}- value: 14
- raw: "14"
}- kind: "init"
}
]
} ObjectExpression {...}
- type: "ObjectExpression"
- start: 209
- end: 238
loc: {...}
start: {...}
- line: 9
- column: 2
}end: {...}
- line: 9
- column: 31
}
}properties: [...] (2)
Property {...}
- type: "Property"
- start: 211
- end: 221
loc: {...}
start: {...}
- line: 9
- column: 4
}end: {...}
- line: 9
- column: 14
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 211
- end: 215
loc: {...}
start: {...}
- line: 9
- column: 4
}end: {...}
- line: 9
- column: 8
}
}- name: "year"
}value: Literal {...}
- type: "Literal"
- start: 217
- end: 221
loc: {...}
start: {...}
- line: 9
- column: 10
}end: {...}
- line: 9
- column: 14
}
}- value: 2010
- raw: "2010"
}- kind: "init"
} Property {...}
- type: "Property"
- start: 223
- end: 236
loc: {...}
start: {...}
- line: 9
- column: 16
}end: {...}
- line: 9
- column: 29
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 223
- end: 232
loc: {...}
start: {...}
- line: 9
- column: 16
}end: {...}
- line: 9
- column: 25
}
}- name: "birthrate"
}value: Literal {...}
- type: "Literal"
- start: 234
- end: 236
loc: {...}
start: {...}
- line: 9
- column: 27
}end: {...}
- line: 9
- column: 29
}
}- value: 13
- raw: "13"
}- kind: "init"
}
]
} ObjectExpression {...}
- type: "ObjectExpression"
- start: 242
- end: 273
loc: {...}
start: {...}
- line: 10
- column: 2
}end: {...}
- line: 10
- column: 33
}
}properties: [...] (2)
Property {...}
- type: "Property"
- start: 244
- end: 254
loc: {...}
start: {...}
- line: 10
- column: 4
}end: {...}
- line: 10
- column: 14
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 244
- end: 248
loc: {...}
start: {...}
- line: 10
- column: 4
}end: {...}
- line: 10
- column: 8
}
}- name: "year"
}value: Literal {...}
- type: "Literal"
- start: 250
- end: 254
loc: {...}
start: {...}
- line: 10
- column: 10
}end: {...}
- line: 10
- column: 14
}
}- value: 2015
- raw: "2015"
}- kind: "init"
} Property {...}
- type: "Property"
- start: 256
- end: 271
loc: {...}
start: {...}
- line: 10
- column: 16
}end: {...}
- line: 10
- column: 31
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 256
- end: 265
loc: {...}
start: {...}
- line: 10
- column: 16
}end: {...}
- line: 10
- column: 25
}
}- name: "birthrate"
}value: Literal {...}
- type: "Literal"
- start: 267
- end: 271
loc: {...}
start: {...}
- line: 10
- column: 27
}end: {...}
- line: 10
- column: 31
}
}- value: 12.4
- raw: "12.4"
}- kind: "init"
}
]
}
]
}
}
]- kind: "const"
} VariableDeclaration {...}
- type: "VariableDeclaration"
- start: 280
- end: 332
loc: {...}
start: {...}
- line: 13
- column: 1
}end: {...}
- line: 13
- column: 53
}
}declarations: [...] (1)
VariableDeclarator {...}
- type: "VariableDeclarator"
- start: 286
- end: 331
loc: {...}
start: {...}
- line: 13
- column: 7
}end: {...}
- line: 13
- column: 52
}
}id: Identifier {...}
- type: "Identifier"
- start: 286
- end: 292
loc: {...}
start: {...}
- line: 13
- column: 7
}end: {...}
- line: 13
- column: 13
}
}- name: "xTicks"
}init: ArrayExpression {...}
- type: "ArrayExpression"
- start: 295
- end: 331
loc: {...}
start: {...}
- line: 13
- column: 16
}end: {...}
- line: 13
- column: 52
}
}elements: [...] (6)
Literal {...}
- type: "Literal"
- start: 296
- end: 300
loc: {...}
start: {...}
- line: 13
- column: 17
}end: {...}
- line: 13
- column: 21
}
}- value: 1990
- raw: "1990"
} Literal {...}
- type: "Literal"
- start: 302
- end: 306
loc: {...}
start: {...}
- line: 13
- column: 23
}end: {...}
- line: 13
- column: 27
}
}- value: 1995
- raw: "1995"
} Literal {...}
- type: "Literal"
- start: 308
- end: 312
loc: {...}
start: {...}
- line: 13
- column: 29
}end: {...}
- line: 13
- column: 33
}
}- value: 2000
- raw: "2000"
} Literal {...}
- type: "Literal"
- start: 314
- end: 318
loc: {...}
start: {...}
- line: 13
- column: 35
}end: {...}
- line: 13
- column: 39
}
}- value: 2005
- raw: "2005"
} Literal {...}
- type: "Literal"
- start: 320
- end: 324
loc: {...}
start: {...}
- line: 13
- column: 41
}end: {...}
- line: 13
- column: 45
}
}- value: 2010
- raw: "2010"
} Literal {...}
- type: "Literal"
- start: 326
- end: 330
loc: {...}
start: {...}
- line: 13
- column: 47
}end: {...}
- line: 13
- column: 51
}
}- value: 2015
- raw: "2015"
}
]
}
}
]- kind: "const"
} VariableDeclaration {...}
- type: "VariableDeclaration"
- start: 334
- end: 368
loc: {...}
start: {...}
- line: 14
- column: 1
}end: {...}
- line: 14
- column: 35
}
}declarations: [...] (1)
VariableDeclarator {...}
- type: "VariableDeclarator"
- start: 340
- end: 367
loc: {...}
start: {...}
- line: 14
- column: 7
}end: {...}
- line: 14
- column: 34
}
}id: Identifier {...}
- type: "Identifier"
- start: 340
- end: 346
loc: {...}
start: {...}
- line: 14
- column: 7
}end: {...}
- line: 14
- column: 13
}
}- name: "yTicks"
}init: ArrayExpression {...}
- type: "ArrayExpression"
- start: 349
- end: 367
loc: {...}
start: {...}
- line: 14
- column: 16
}end: {...}
- line: 14
- column: 34
}
}elements: [...] (5)
Literal {...}
- type: "Literal"
- start: 350
- end: 351
loc: {...}
start: {...}
- line: 14
- column: 17
}end: {...}
- line: 14
- column: 18
}
}- value: 0
- raw: "0"
} Literal {...}
- type: "Literal"
- start: 353
- end: 354
loc: {...}
start: {...}
- line: 14
- column: 20
}end: {...}
- line: 14
- column: 21
}
}- value: 5
- raw: "5"
} Literal {...}
- type: "Literal"
- start: 356
- end: 358
loc: {...}
start: {...}
- line: 14
- column: 23
}end: {...}
- line: 14
- column: 25
}
}- value: 10
- raw: "10"
} Literal {...}
- type: "Literal"
- start: 360
- end: 362
loc: {...}
start: {...}
- line: 14
- column: 27
}end: {...}
- line: 14
- column: 29
}
}- value: 15
- raw: "15"
} Literal {...}
- type: "Literal"
- start: 364
- end: 366
loc: {...}
start: {...}
- line: 14
- column: 31
}end: {...}
- line: 14
- column: 33
}
}- value: 20
- raw: "20"
}
]
}
}
]- kind: "const"
} VariableDeclaration {...}
- type: "VariableDeclaration"
- start: 370
- end: 431
loc: {...}
start: {...}
- line: 15
- column: 1
}end: {...}
- line: 15
- column: 62
}
}declarations: [...] (1)
VariableDeclarator {...}
- type: "VariableDeclarator"
- start: 376
- end: 430
loc: {...}
start: {...}
- line: 15
- column: 7
}end: {...}
- line: 15
- column: 61
}
}id: Identifier {...}
- type: "Identifier"
- start: 376
- end: 383
loc: {...}
start: {...}
- line: 15
- column: 7
}end: {...}
- line: 15
- column: 14
}
}- name: "padding"
}init: ObjectExpression {...}
- type: "ObjectExpression"
- start: 386
- end: 430
loc: {...}
start: {...}
- line: 15
- column: 17
}end: {...}
- line: 15
- column: 61
}
}properties: [...] (4)
Property {...}
- type: "Property"
- start: 388
- end: 395
loc: {...}
start: {...}
- line: 15
- column: 19
}end: {...}
- line: 15
- column: 26
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 388
- end: 391
loc: {...}
start: {...}
- line: 15
- column: 19
}end: {...}
- line: 15
- column: 22
}
}- name: "top"
}value: Literal {...}
- type: "Literal"
- start: 393
- end: 395
loc: {...}
start: {...}
- line: 15
- column: 24
}end: {...}
- line: 15
- column: 26
}
}- value: 20
- raw: "20"
}- kind: "init"
} Property {...}
- type: "Property"
- start: 397
- end: 406
loc: {...}
start: {...}
- line: 15
- column: 28
}end: {...}
- line: 15
- column: 37
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 397
- end: 402
loc: {...}
start: {...}
- line: 15
- column: 28
}end: {...}
- line: 15
- column: 33
}
}- name: "right"
}value: Literal {...}
- type: "Literal"
- start: 404
- end: 406
loc: {...}
start: {...}
- line: 15
- column: 35
}end: {...}
- line: 15
- column: 37
}
}- value: 15
- raw: "15"
}- kind: "init"
} Property {...}
- type: "Property"
- start: 408
- end: 418
loc: {...}
start: {...}
- line: 15
- column: 39
}end: {...}
- line: 15
- column: 49
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 408
- end: 414
loc: {...}
start: {...}
- line: 15
- column: 39
}end: {...}
- line: 15
- column: 45
}
}- name: "bottom"
}value: Literal {...}
- type: "Literal"
- start: 416
- end: 418
loc: {...}
start: {...}
- line: 15
- column: 47
}end: {...}
- line: 15
- column: 49
}
}- value: 20
- raw: "20"
}- kind: "init"
} Property {...}
- type: "Property"
- start: 420
- end: 428
loc: {...}
start: {...}
- line: 15
- column: 51
}end: {...}
- line: 15
- column: 59
}
}- method: false
- shorthand: false
- computed: false
key: Identifier {...}
- type: "Identifier"
- start: 420
- end: 424
loc: {...}
start: {...}
- line: 15
- column: 51
}end: {...}
- line: 15
- column: 55
}
}- name: "left"
}value: Literal {...}
- type: "Literal"
- start: 426
- end: 428
loc: {...}
start: {...}
- line: 15
- column: 57
}end: {...}
- line: 15
- column: 59
}
}- value: 25
- raw: "25"
}- kind: "init"
}
]
}
}
]- kind: "const"
} VariableDeclaration {...}
- type: "VariableDeclaration"
- start: 434
- end: 458
loc: {...}
start: {...}
- line: 17
- column: 1
}end: {...}
- line: 17
- column: 25
}
}declarations: [...] (1)
VariableDeclarator {...}
- type: "VariableDeclarator"
- start: 438
- end: 457
loc: {...}
start: {...}
- line: 17
- column: 5
}end: {...}
- line: 17
- column: 24
}
}id: Identifier {...}
- type: "Identifier"
- start: 438
- end: 443
loc: {...}
start: {...}
- line: 17
- column: 5
}end: {...}
- line: 17
- column: 10
}
}- name: "width"
}init: CallExpression {...}
- type: "CallExpression"
- start: 446
- end: 457
loc: {...}
start: {...}
- line: 17
- column: 13
}end: {...}
- line: 17
- column: 24
}
}callee: Identifier {...}
- type: "Identifier"
- start: 446
- end: 452
loc: {...}
start: {...}
- line: 17
- column: 13
}end: {...}
- line: 17
- column: 19
}
}- name: "$state"
}arguments: [...] (1)
Literal {...}
- type: "Literal"
- start: 453
- end: 456
loc: {...}
start: {...}
- line: 17
- column: 20
}end: {...}
- line: 17
- column: 23
}
}- value: 500
- raw: "500"
}
]- optional: false
}
}
]- kind: "let"
} VariableDeclaration {...}
- type: "VariableDeclaration"
- start: 460
- end: 485
loc: {...}
start: {...}
- line: 18
- column: 1
}end: {...}
- line: 18
- column: 26
}
}declarations: [...] (1)
VariableDeclarator {...}
- type: "VariableDeclarator"
- start: 464
- end: 484
loc: {...}
start: {...}
- line: 18
- column: 5
}end: {...}
- line: 18
- column: 25
}
}id: Identifier {...}
- type: "Identifier"
- start: 464
- end: 470
loc: {...}
start: {...}
- line: 18
- column: 5
}end: {...}
- line: 18
- column: 11
}
}- name: "height"
}init: CallExpression {...}
- type: "CallExpression"
- start: 473
- end: 484
loc: {...}
start: {...}
- line: 18
- column: 14
}end: {...}
- line: 18
- column: 25
}
}callee: Identifier {...}
- type: "Identifier"
- start: 473
- end: 479
loc: {...}
start: {...}
- line: 18
- column: 14
}end: {...}
- line: 18
- column: 20
}
}- name: "$state"
}arguments: [...] (1)
Literal {...}
- type: "Literal"
- start: 480
- end: 483
loc: {...}
start: {...}
- line: 18
- column: 21
}end: {...}
- line: 18
- column: 24
}
}- value: 200
- raw: "200"
}
]- optional: false
}
}
]- kind: "let"
} FunctionDeclaration {...}
- type: "FunctionDeclaration"
- start: 488
- end: 562
loc: {...}
start: {...}
- line: 20
- column: 1
}end: {...}
- line: 22
- column: 2
}
}id: Identifier {...}
- type: "Identifier"
- start: 497
- end: 509
loc: {...}
start: {...}
- line: 20
- column: 10
}end: {...}
- line: 20
- column: 22
}
}- name: "formatMobile"
}- expression: false
- generator: false
- async: false
params: [...] (1)
Identifier {...}
- type: "Identifier"
- start: 510
- end: 514
loc: {...}
start: {...}
- line: 20
- column: 23
}end: {...}
- line: 20
- column: 27
}
}- name: "tick"
}
]body: BlockStatement {...}
- type: "BlockStatement"
- start: 516
- end: 562
loc: {...}
start: {...}
- line: 20
- column: 29
}end: {...}
- line: 22
- column: 2
}
}body: [...] (1)
ReturnStatement {...}
- type: "ReturnStatement"
- start: 520
- end: 559
loc: {...}
start: {...}
- line: 21
- column: 2
}end: {...}
- line: 21
- column: 41
}
}argument: BinaryExpression {...}
- type: "BinaryExpression"
- start: 527
- end: 558
loc: {...}
start: {...}
- line: 21
- column: 9
}end: {...}
- line: 21
- column: 40
}
}left: Literal {...}
- type: "Literal"
- start: 527
- end: 530
loc: {...}
start: {...}
- line: 21
- column: 9
}end: {...}
- line: 21
- column: 12
}
}- value: "'"
- raw: "\"'\""
}- operator: "+"
right: CallExpression {...}
- type: "CallExpression"
- start: 533
- end: 558
loc: {...}
start: {...}
- line: 21
- column: 15
}end: {...}
- line: 21
- column: 40
}
}callee: MemberExpression {...}
- type: "MemberExpression"
- start: 533
- end: 554
loc: {...}
start: {...}
- line: 21
- column: 15
}end: {...}
- line: 21
- column: 36
}
}object: CallExpression {...}
- type: "CallExpression"
- start: 533
- end: 548
loc: {...}
start: {...}
- line: 21
- column: 15
}end: {...}
- line: 21
- column: 30
}
}callee: MemberExpression {...}
- type: "MemberExpression"
- start: 533
- end: 546
loc: {...}
start: {...}
- line: 21
- column: 15
}end: {...}
- line: 21
- column: 28
}
}object: Identifier {...}
- type: "Identifier"
- start: 533
- end: 537
loc: {...}
start: {...}
- line: 21
- column: 15
}end: {...}
- line: 21
- column: 19
}
}- name: "tick"
}property: Identifier {...}
- type: "Identifier"
- start: 538
- end: 546
loc: {...}
start: {...}
- line: 21
- column: 20
}end: {...}
- line: 21
- column: 28
}
}- name: "toString"
}- computed: false
- optional: false
}- arguments: []
- optional: false
}property: Identifier {...}
- type: "Identifier"
- start: 549
- end: 554
loc: {...}
start: {...}
- line: 21
- column: 31
}end: {...}
- line: 21
- column: 36
}
}- name: "slice"
}- computed: false
- optional: false
}arguments: [...] (1)
UnaryExpression {...}
- type: "UnaryExpression"
- start: 555
- end: 557
loc: {...}
start: {...}
- line: 21
- column: 37
}end: {...}
- line: 21
- column: 39
}
}- operator: "-"
- prefix: true
argument: Literal {...}
- type: "Literal"
- start: 556
- end: 557
loc: {...}
start: {...}
- line: 21
- column: 38
}end: {...}
- line: 21
- column: 39
}
}- value: 2
- raw: "2"
}
}
]- optional: false
}
}
}
]
}
} VariableDeclaration {...}
- type: "VariableDeclaration"
- start: 565
- end: 680
loc: {...}
start: {...}
- line: 24
- column: 1
}end: {...}
- line: 26
- column: 49
}
}declarations: [...] (1)
VariableDeclarator {...}
- type: "VariableDeclarator"
- start: 569
- end: 679
loc: {...}
start: {...}
- line: 24
- column: 5
}end: {...}
- line: 26
- column: 48
}
}id: Identifier {...}
- type: "Identifier"
- start: 569
- end: 575
loc: {...}
start: {...}
- line: 24
- column: 5
}end: {...}
- line: 24
- column: 11
}
}- name: "xScale"
}init: CallExpression {...}
- type: "CallExpression"
- start: 578
- end: 679
loc: {...}
start: {...}
- line: 24
- column: 14
}end: {...}
- line: 26
- column: 48
}
}callee: Identifier {...}
- type: "Identifier"
- start: 578
- end: 586
loc: {...}
start: {...}
- line: 24
- column: 14
}end: {...}
- line: 24
- column: 22
}
}- name: "$derived"
}arguments: [...] (1)
CallExpression {...}
- type: "CallExpression"
- start: 587
- end: 678
loc: {...}
start: {...}
- line: 24
- column: 23
}end: {...}
- line: 26
- column: 47
}
}callee: MemberExpression {...}
- type: "MemberExpression"
- start: 587
- end: 639
loc: {...}
start: {...}
- line: 24
- column: 23
}end: {...}
- line: 26
- column: 8
}
}object: CallExpression {...}
- type: "CallExpression"
- start: 587
- end: 630
loc: {...}
start: {...}
- line: 24
- column: 23
}end: {...}
- line: 25
- column: 29
}
}callee: MemberExpression {...}
- type: "MemberExpression"
- start: 587
- end: 610
loc: {...}
start: {...}
- line: 24
- column: 23
}end: {...}
- line: 25
- column: 9
}
}object: CallExpression {...}
- type: "CallExpression"
- start: 587
- end: 600
loc: {...}
start: {...}
- line: 24
- column: 23
}end: {...}
- line: 24
- column: 36
}
}callee: Identifier {...}
- type: "Identifier"
- start: 587
- end: 598
loc: {...}
start: {...}
- line: 24
- column: 23
}end: {...}
- line: 24
- column: 34
}
}- name: "scaleLinear"
}- arguments: []
- optional: false
}property: Identifier {...}
- type: "Identifier"
- start: 604
- end: 610
loc: {...}
start: {...}
- line: 25
- column: 3
}end: {...}
- line: 25
- column: 9
}
}- name: "domain"
}- computed: false
- optional: false
}arguments: [...] (1)
ArrayExpression {...}
- type: "ArrayExpression"
- start: 611
- end: 629
loc: {...}
start: {...}
- line: 25
- column: 10
}end: {...}
- line: 25
- column: 28
}
}elements: [...] (2)
Literal {...}
- type: "Literal"
- start: 612
- end: 613
loc: {...}
start: {...}
- line: 25
- column: 11
}end: {...}
- line: 25
- column: 12
}
}- value: 0
- raw: "0"
} MemberExpression {...}
- type: "MemberExpression"
- start: 615
- end: 628
loc: {...}
start: {...}
- line: 25
- column: 14
}end: {...}
- line: 25
- column: 27
}
}object: Identifier {...}
- type: "Identifier"
- start: 615
- end: 621
loc: {...}
start: {...}
- line: 25
- column: 14
}end: {...}
- line: 25
- column: 20
}
}- name: "xTicks"
}property: Identifier {...}
- type: "Identifier"
- start: 622
- end: 628
loc: {...}
start: {...}
- line: 25
- column: 21
}end: {...}
- line: 25
- column: 27
}
}- name: "length"
}- computed: false
- optional: false
}
]
}
]- optional: false
}property: Identifier {...}
- type: "Identifier"
- start: 634
- end: 639
loc: {...}
start: {...}
- line: 26
- column: 3
}end: {...}
- line: 26
- column: 8
}
}- name: "range"
}- computed: false
- optional: false
}arguments: [...] (1)
ArrayExpression {...}
- type: "ArrayExpression"
- start: 640
- end: 677
loc: {...}
start: {...}
- line: 26
- column: 9
}end: {...}
- line: 26
- column: 46
}
}elements: [...] (2)
MemberExpression {...}
- type: "MemberExpression"
- start: 641
- end: 653
loc: {...}
start: {...}
- line: 26
- column: 10
}end: {...}
- line: 26
- column: 22
}
}object: Identifier {...}
- type: "Identifier"
- start: 641
- end: 648
loc: {...}
start: {...}
- line: 26
- column: 10
}end: {...}
- line: 26
- column: 17
}
}- name: "padding"
}property: Identifier {...}
- type: "Identifier"
- start: 649
- end: 653
loc: {...}
start: {...}
- line: 26
- column: 18
}end: {...}
- line: 26
- column: 22
}
}- name: "left"
}- computed: false
- optional: false
} BinaryExpression {...}
- type: "BinaryExpression"
- start: 655
- end: 676
loc: {...}
start: {...}
- line: 26
- column: 24
}end: {...}
- line: 26
- column: 45
}
}left: Identifier {...}
- type: "Identifier"
- start: 655
- end: 660
loc: {...}
start: {...}
- line: 26
- column: 24
}end: {...}
- line: 26
- column: 29
}
}- name: "width"
}- operator: "-"
right: MemberExpression {...}
- type: "MemberExpression"
- start: 663
- end: 676
loc: {...}
start: {...}
- line: 26
- column: 32
}end: {...}
- line: 26
- column: 45
}
}object: Identifier {...}
- type: "Identifier"
- start: 663
- end: 670
loc: {...}
start: {...}
- line: 26
- column: 32
}end: {...}
- line: 26
- column: 39
}
}- name: "padding"
}property: Identifier {...}
- type: "Identifier"
- start: 671
- end: 676
loc: {...}
start: {...}
- line: 26
- column: 40
}end: {...}
- line: 26
- column: 45
}
}- name: "right"
}- computed: false
- optional: false
}
}
]
}
]- optional: false
}
]- optional: false
}
}
]- kind: "let"
} VariableDeclaration {...}
- type: "VariableDeclaration"
- start: 683
- end: 814
loc: {...}
start: {...}
- line: 28
- column: 1
}end: {...}
- line: 30
- column: 50
}
}declarations: [...] (1)
VariableDeclarator {...}
- type: "VariableDeclarator"
- start: 687
- end: 813
loc: {...}
start: {...}
- line: 28
- column: 5
}end: {...}
- line: 30
- column: 49
}
}id: Identifier {...}
- type: "Identifier"
- start: 687
- end: 693
loc: {...}
start: {...}
- line: 28
- column: 5
}end: {...}
- line: 28
- column: 11
}
}- name: "yScale"
}init: CallExpression {...}
- type: "CallExpression"
- start: 696
- end: 813
loc: {...}
start: {...}
- line: 28
- column: 14
}end: {...}
- line: 30
- column: 49
}
}callee: Identifier {...}
- type: "Identifier"
- start: 696
- end: 704
loc: {...}
start: {...}
- line: 28
- column: 14
}end: {...}
- line: 28
- column: 22
}
}- name: "$derived"
}arguments: [...] (1)
CallExpression {...}
- type: "CallExpression"
- start: 705
- end: 812
loc: {...}
start: {...}
- line: 28
- column: 23
}end: {...}
- line: 30
- column: 48
}
}callee: MemberExpression {...}
- type: "MemberExpression"
- start: 705
- end: 772
loc: {...}
start: {...}
- line: 28
- column: 23
}end: {...}
- line: 30
- column: 8
}
}object: CallExpression {...}
- type: "CallExpression"
- start: 705
- end: 763
loc: {...}
start: {...}
- line: 28
- column: 23
}end: {...}
- line: 29
- column: 44
}
}callee: MemberExpression {...}
- type: "MemberExpression"
- start: 705
- end: 728
loc: {...}
start: {...}
- line: 28
- column: 23
}end: {...}
- line: 29
- column: 9
}
}object: CallExpression {...}
- type: "CallExpression"
- start: 705
- end: 718
loc: {...}
start: {...}
- line: 28
- column: 23
}end: {...}
- line: 28
- column: 36
}
}callee: Identifier {...}
- type: "Identifier"
- start: 705
- end: 716
loc: {...}
start: {...}
- line: 28
- column: 23
}end: {...}
- line: 28
- column: 34
}
}- name: "scaleLinear"
}- arguments: []
- optional: false
}property: Identifier {...}
- type: "Identifier"
- start: 722
- end: 728
loc: {...}
start: {...}
- line: 29
- column: 3
}end: {...}
- line: 29
- column: 9
}
}- name: "domain"
}- computed: false
- optional: false
}arguments: [...] (1)
ArrayExpression {...}
- type: "ArrayExpression"
- start: 729
- end: 762
loc: {...}
start: {...}
- line: 29
- column: 10
}end: {...}
- line: 29
- column: 43
}
}elements: [...] (2)
Literal {...}
- type: "Literal"
- start: 730
- end: 731
loc: {...}
start: {...}
- line: 29
- column: 11
}end: {...}
- line: 29
- column: 12
}
}- value: 0
- raw: "0"
} CallExpression {...}
- type: "CallExpression"
- start: 733
- end: 761
loc: {...}
start: {...}
- line: 29
- column: 14
}end: {...}
- line: 29
- column: 42
}
}callee: MemberExpression {...}
- type: "MemberExpression"
- start: 733
- end: 747
loc: {...}
start: {...}
- line: 29
- column: 14
}end: {...}
- line: 29
- column: 28
}
}object: MemberExpression {...}
- type: "MemberExpression"
- start: 733
- end: 741
loc: {...}
start: {...}
- line: 29
- column: 14
}end: {...}
- line: 29
- column: 22
}
}object: Identifier {...}
- type: "Identifier"
- start: 733
- end: 737
loc: {...}
start: {...}
- line: 29
- column: 14
}end: {...}
- line: 29
- column: 18
}
}- name: "Math"
}property: Identifier {...}
- type: "Identifier"
- start: 738
- end: 741
loc: {...}
start: {...}
- line: 29
- column: 19
}end: {...}
- line: 29
- column: 22
}
}- name: "max"
}- computed: false
- optional: false
}property: Identifier {...}
- type: "Identifier"
- start: 742
- end: 747
loc: {...}
start: {...}
- line: 29
- column: 23
}end: {...}
- line: 29
- column: 28
}
}- name: "apply"
}- computed: false
- optional: false
}arguments: [...] (2)
Literal {...}
- type: "Literal"
- start: 748
- end: 752
loc: {...}
start: {...}
- line: 29
- column: 29
}end: {...}
- line: 29
- column: 33
}
}- value: null
- raw: "null"
} Identifier {...}
- type: "Identifier"
- start: 754
- end: 760
loc: {...}
start: {...}
- line: 29
- column: 35
}end: {...}
- line: 29
- column: 41
}
}- name: "yTicks"
}
]- optional: false
}
]
}
]- optional: false
}property: Identifier {...}
- type: "Identifier"
- start: 767
- end: 772
loc: {...}
start: {...}
- line: 30
- column: 3
}end: {...}
- line: 30
- column: 8
}
}- name: "range"
}- computed: false
- optional: false
}arguments: [...] (1)
ArrayExpression {...}
- type: "ArrayExpression"
- start: 773
- end: 811
loc: {...}
start: {...}
- line: 30
- column: 9
}end: {...}
- line: 30
- column: 47
}
}elements: [...] (2)
BinaryExpression {...}
- type: "BinaryExpression"
- start: 774
- end: 797
loc: {...}
start: {...}
- line: 30
- column: 10
}end: {...}
- line: 30
- column: 33
}
}left: Identifier {...}
- type: "Identifier"
- start: 774
- end: 780
loc: {...}
start: {...}
- line: 30
- column: 10
}end: {...}
- line: 30
- column: 16
}
}- name: "height"
}- operator: "-"
right: MemberExpression {...}
- type: "MemberExpression"
- start: 783
- end: 797
loc: {...}
start: {...}
- line: 30
- column: 19
}end: {...}
- line: 30
- column: 33
}
}object: Identifier {...}
- type: "Identifier"
- start: 783
- end: 790
loc: {...}
start: {...}
- line: 30
- column: 19
}end: {...}
- line: 30
- column: 26
}
}- name: "padding"
}property: Identifier {...}
- type: "Identifier"
- start: 791
- end: 797
loc: {...}
start: {...}
- line: 30
- column: 27
}end: {...}
- line: 30
- column: 33
}
}- name: "bottom"
}- computed: false
- optional: false
}
} MemberExpression {...}
- type: "MemberExpression"
- start: 799
- end: 810
loc: {...}
start: {...}
- line: 30
- column: 35
}end: {...}
- line: 30
- column: 46
}
}object: Identifier {...}
- type: "Identifier"
- start: 799
- end: 806
loc: {...}
start: {...}
- line: 30
- column: 35
}end: {...}
- line: 30
- column: 42
}
}- name: "padding"
}property: Identifier {...}
- type: "Identifier"
- start: 807
- end: 810
loc: {...}
start: {...}
- line: 30
- column: 43
}end: {...}
- line: 30
- column: 46
}
}- name: "top"
}- computed: false
- optional: false
}
]
}
]- optional: false
}
]- optional: false
}
}
]- kind: "let"
} VariableDeclaration {...}
- type: "VariableDeclaration"
- start: 817
- end: 883
loc: {...}
start: {...}
- line: 32
- column: 1
}end: {...}
- line: 32
- column: 67
}
}declarations: [...] (1)
VariableDeclarator {...}
- type: "VariableDeclarator"
- start: 821
- end: 882
loc: {...}
start: {...}
- line: 32
- column: 5
}end: {...}
- line: 32
- column: 66
}
}id: Identifier {...}
- type: "Identifier"
- start: 821
- end: 831
loc: {...}
start: {...}
- line: 32
- column: 5
}end: {...}
- line: 32
- column: 15
}
}- name: "innerWidth"
}init: CallExpression {...}
- type: "CallExpression"
- start: 834
- end: 882
loc: {...}
start: {...}
- line: 32
- column: 18
}end: {...}
- line: 32
- column: 66
}
}callee: Identifier {...}
- type: "Identifier"
- start: 834
- end: 842
loc: {...}
start: {...}
- line: 32
- column: 18
}end: {...}
- line: 32
- column: 26
}
}- name: "$derived"
}arguments: [...] (1)
BinaryExpression {...}
- type: "BinaryExpression"
- start: 843
- end: 881
loc: {...}
start: {...}
- line: 32
- column: 27
}end: {...}
- line: 32
- column: 65
}
}left: Identifier {...}
- type: "Identifier"
- start: 843
- end: 848
loc: {...}
start: {...}
- line: 32
- column: 27
}end: {...}
- line: 32
- column: 32
}
}- name: "width"
}- operator: "-"
right: BinaryExpression {...}
- type: "BinaryExpression"
- start: 852
- end: 880
loc: {...}
start: {...}
- line: 32
- column: 36
}end: {...}
- line: 32
- column: 64
}
}left: MemberExpression {...}
- type: "MemberExpression"
- start: 852
- end: 864
loc: {...}
start: {...}
- line: 32
- column: 36
}end: {...}
- line: 32
- column: 48
}
}object: Identifier {...}
- type: "Identifier"
- start: 852
- end: 859
loc: {...}
start: {...}
- line: 32
- column: 36
}end: {...}
- line: 32
- column: 43
}
}- name: "padding"
}property: Identifier {...}
- type: "Identifier"
- start: 860
- end: 864
loc: {...}
start: {...}
- line: 32
- column: 44
}end: {...}
- line: 32
- column: 48
}
}- name: "left"
}- computed: false
- optional: false
}- operator: "+"
right: MemberExpression {...}
- type: "MemberExpression"
- start: 867
- end: 880
loc: {...}
start: {...}
- line: 32
- column: 51
}end: {...}
- line: 32
- column: 64
}
}object: Identifier {...}
- type: "Identifier"
- start: 867
- end: 874
loc: {...}
start: {...}
- line: 32
- column: 51
}end: {...}
- line: 32
- column: 58
}
}- name: "padding"
}property: Identifier {...}
- type: "Identifier"
- start: 875
- end: 880
loc: {...}
start: {...}
- line: 32
- column: 59
}end: {...}
- line: 32
- column: 64
}
}- name: "right"
}- computed: false
- optional: false
}
}
}
]- optional: false
}
}
]- kind: "let"
} VariableDeclaration {...}
- type: "VariableDeclaration"
- start: 885
- end: 937
loc: {...}
start: {...}
- line: 33
- column: 1
}end: {...}
- line: 33
- column: 53
}
}declarations: [...] (1)
VariableDeclarator {...}
- type: "VariableDeclarator"
- start: 889
- end: 936
loc: {...}
start: {...}
- line: 33
- column: 5
}end: {...}
- line: 33
- column: 52
}
}id: Identifier {...}
- type: "Identifier"
- start: 889
- end: 897
loc: {...}
start: {...}
- line: 33
- column: 5
}end: {...}
- line: 33
- column: 13
}
}- name: "barWidth"
}init: CallExpression {...}
- type: "CallExpression"
- start: 900
- end: 936
loc: {...}
start: {...}
- line: 33
- column: 16
}end: {...}
- line: 33
- column: 52
}
}callee: Identifier {...}
- type: "Identifier"
- start: 900
- end: 908
loc: {...}
start: {...}
- line: 33
- column: 16
}end: {...}
- line: 33
- column: 24
}
}- name: "$derived"
}arguments: [...] (1)
BinaryExpression {...}
- type: "BinaryExpression"
- start: 909
- end: 935
loc: {...}
start: {...}
- line: 33
- column: 25
}end: {...}
- line: 33
- column: 51
}
}left: Identifier {...}
- type: "Identifier"
- start: 909
- end: 919
loc: {...}
start: {...}
- line: 33
- column: 25
}end: {...}
- line: 33
- column: 35
}
}- name: "innerWidth"
}- operator: "/"
right: MemberExpression {...}
- type: "MemberExpression"
- start: 922
- end: 935
loc: {...}
start: {...}
- line: 33
- column: 38
}end: {...}
- line: 33
- column: 51
}
}object: Identifier {...}
- type: "Identifier"
- start: 922
- end: 928
loc: {...}
start: {...}
- line: 33
- column: 38
}end: {...}
- line: 33
- column: 44
}
}- name: "xTicks"
}property: Identifier {...}
- type: "Identifier"
- start: 929
- end: 935
loc: {...}
start: {...}
- line: 33
- column: 45
}end: {...}
- line: 33
- column: 51
}
}- name: "length"
}- computed: false
- optional: false
}
}
]- optional: false
}
}
]- kind: "let"
}
]- sourceType: "module"
}- attributes: []
}
}
The AST is not public API and may change at any point in time