Skip to content

Commit

Permalink
💅Prettify code
Browse files Browse the repository at this point in the history
  • Loading branch information
JasonBoy committed Jul 23, 2019
1 parent 520d256 commit f9d89d0
Show file tree
Hide file tree
Showing 7 changed files with 5,293 additions and 13 deletions.
6 changes: 3 additions & 3 deletions __tests__/ChinaLocation.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ import list from "../dist/location.json";
import ChinaLocation from "../lib/ChinaLocation";

describe("ChinaLocation", function() {
let newProvince;
let newCity;
let newDistrict;
let newProvince: string;
let newCity: string;
let newDistrict: string;

beforeAll(() => {
newProvince = "320000";
Expand Down
2 changes: 1 addition & 1 deletion dist/location.json
Original file line number Diff line number Diff line change
Expand Up @@ -5309,4 +5309,4 @@
}
}
}
}
}
5,284 changes: 5,283 additions & 1 deletion dist/location.min.json

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions jest.config.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module.exports = {
preset: 'ts-jest',
testEnvironment: 'node',
};
preset: "ts-jest",
testEnvironment: "node"
};
2 changes: 1 addition & 1 deletion lib/ChinaLocation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ class ChinaLocation {
districtCode: string,
cityCode: string,
provinceCode: string
) {
): string {
return this.getCityByCode(cityCode, provinceCode).districts[districtCode];
}

Expand Down
2 changes: 1 addition & 1 deletion scripts/reformat.ts
Original file line number Diff line number Diff line change
Expand Up @@ -122,4 +122,4 @@ function getDistricts(cityCode) {
return result;
}

processLocation().then(() => console.log('Reformat list finished!'));
processLocation().then(() => console.log("Reformat list finished!"));
4 changes: 1 addition & 3 deletions tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,5 @@
"esModuleInterop": true,
"target": "es2015"
},
"include": [
"lib/*.ts"
]
"include": ["lib/*.ts"]
}

0 comments on commit f9d89d0

Please sign in to comment.