Skip to content

Commit

Permalink
Cleaning up vegagoja.js
Browse files Browse the repository at this point in the history
  • Loading branch information
kenshaw committed Jan 22, 2024
1 parent 5249b33 commit 843e886
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions vegagoja.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ function version() {
}

function compile(logf, spec) {
var res = {};
let res;
try {
res = vegaLite.compile(parse(spec), {
logger: logger(logf),
Expand All @@ -51,7 +51,7 @@ function compile(logf, spec) {
function loader(logf, loadf) {
return {
async load(name, res) {
var s = "";
let s;
try {
s = loadf(name, res.response);
} catch (e) {
Expand Down Expand Up @@ -93,8 +93,8 @@ function loader(logf, loadf) {
}

async function render(logf, spec, loadf) {
var runtime = vega.parse(parse(spec));
var view = new vega.View(runtime, {
let runtime = vega.parse(parse(spec));
let view = new vega.View(runtime, {
logLevel: vega.Debug,
logger: logger(logf),
loader: loader(logf, loadf),
Expand Down

0 comments on commit 843e886

Please sign in to comment.