File tree 2 files changed +26
-4
lines changed
2 files changed +26
-4
lines changed Original file line number Diff line number Diff line change 1
1
2
- {{ $jsPath := .Get "path" }}
3
- {{ $dimensionsRef := getJSON $jsPath }}
2
+ {{ $rawJSPath := .Get "path" }}
3
+ {{ $jsPath := replace $rawJSPath "/static" "" }}
4
+ {{ $dimensionsRef := dict }}
5
+ {{ with resources.Get $jsPath }}
6
+ {{ with .Err }}
7
+ {{ errorf "%s" . }}
8
+ {{ else }}
9
+ {{ $dimensionsRef = . | transform.Unmarshal }}
10
+ {{ end }}
11
+ {{ else }}
12
+ {{ errorf "Unable to get asset resource %q" $jsPath }}
13
+ {{ end }}
14
+
4
15
5
16
< div class ="row flex-xl-nowrap ">
6
17
Original file line number Diff line number Diff line change 1
1
2
- {{ $jsPath := .Get "path" }}
3
- {{ $metricsRef := getJSON $jsPath }}
2
+ {{ $rawJSPath := .Get "path" }}
3
+ {{ $jsPath := replace $rawJSPath "/static" "" }}
4
+ {{ $metricsRef := dict }}
5
+ {{ with resources.Get $jsPath }}
6
+ {{ with .Err }}
7
+ {{ errorf "%s" . }}
8
+ {{ else }}
9
+ {{ $metricsRef = . | transform.Unmarshal }}
10
+ {{ end }}
11
+ {{ else }}
12
+ {{ errorf "Unable to get asset resource %q" $jsPath }}
13
+ {{ end }}
14
+
4
15
5
16
6
17
You can’t perform that action at this time.
0 commit comments