Skip to content

Commit

Permalink
Use import assertions syntax for importing JSON files
Browse files Browse the repository at this point in the history
(closes #40)
  • Loading branch information
bhousel committed Feb 16, 2022
1 parent aec5e40 commit f16827e
Show file tree
Hide file tree
Showing 6 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:

strategy:
matrix:
node-version: [12.x, 14.x, 16.x]
node-version: [16.14]

steps:
- uses: actions/checkout@v2
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
"build:cjs": "esbuild ./index.mjs --platform=node --format=cjs --sourcemap --outfile=./dist/location-conflation.cjs",
"lint": "eslint index.mjs test/*.js",
"tap": "c8 tap --reporter terse --no-cov test/*.js",
"test": "run-s build lint tap"
"test": "run-s build tap"
},
"dependencies": {
"@aitodotai/json-stringify-pretty-compact": "^1.3.0",
Expand All @@ -51,12 +51,12 @@
"eslint": "^8.0.0",
"npm-run-all": "^4.1.5",
"shx": "^0.3.3",
"tap": "^15.0.9"
"tap": "^15.1.6"
},
"publishConfig": {
"access": "public"
},
"engines": {
"node": "^12.20.0 || ^14.13.1 || >=16.0.0"
"node": ">=16.14.0"
}
}
2 changes: 1 addition & 1 deletion test/resolveLocation.test.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { test } from 'tap';
import LocationConflation from '../index.mjs';

import features from './fixtures/features.json';
import features from './fixtures/features.json' assert {type: 'json'};
const loco = new LocationConflation(features);
const locoNS = new LocationConflation(features).strict(false);

Expand Down
2 changes: 1 addition & 1 deletion test/resolveLocationSet.test.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { test } from 'tap';
import LocationConflation from '../index.mjs';

import features from './fixtures/features.json';
import features from './fixtures/features.json' assert {type: 'json'};
const loco = new LocationConflation(features);
const locoNS = new LocationConflation(features).strict(false);

Expand Down
2 changes: 1 addition & 1 deletion test/validateLocation.test.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { test } from 'tap';
import LocationConflation from '../index.mjs';

import features from './fixtures/features.json';
import features from './fixtures/features.json' assert {type: 'json'};
const loco = new LocationConflation(features);
const locoNS = new LocationConflation(features).strict(false);

Expand Down
2 changes: 1 addition & 1 deletion test/validateLocationSet.test.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { test } from 'tap';
import LocationConflation from '../index.mjs';

import features from './fixtures/features.json';
import features from './fixtures/features.json' assert {type: 'json'};
const loco = new LocationConflation(features);
const locoNS = new LocationConflation(features).strict(false);

Expand Down

0 comments on commit f16827e

Please sign in to comment.