Comparing version 1.0.3 to 1.1.0
import { OneMap } from './OneMap'; | ||
export default OneMap; | ||
export = OneMap; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
const OneMap_1 = require("./OneMap"); | ||
exports.default = OneMap_1.OneMap; | ||
module.exports = OneMap_1.OneMap; |
@@ -1,4 +0,4 @@ | ||
import OneMap from '..'; | ||
import { OneMap } from '../OneMap'; | ||
import { ApiRes } from '../types'; | ||
import { Service } from '.'; | ||
import { ApiRes } from '../types'; | ||
export interface GetTokennRes extends ApiRes { | ||
@@ -5,0 +5,0 @@ access_token: string; |
@@ -17,3 +17,3 @@ "use strict"; | ||
const axios_1 = __importDefault(require("axios")); | ||
const __1 = __importDefault(require("..")); | ||
const OneMap_1 = require("../OneMap"); | ||
const _1 = require("."); | ||
@@ -33,3 +33,3 @@ class Auth extends _1.Service { | ||
} | ||
const response = yield axios_1.default(`${__1.default.BASE_URL}/privateapi/auth/post/getToken`, { | ||
const response = yield axios_1.default(`${OneMap_1.OneMap.BASE_URL}/privateapi/auth/post/getToken`, { | ||
proxy: (_f = this.onemap.options) === null || _f === void 0 ? void 0 : _f.proxy, | ||
@@ -36,0 +36,0 @@ method: 'POST', |
@@ -1,4 +0,4 @@ | ||
import OneMap from '..'; | ||
import { OneMap } from '../OneMap'; | ||
import { Coordinates, ApiRes } from '../types'; | ||
import { Service } from '.'; | ||
import { Coordinates, ApiRes } from '../types'; | ||
export interface RevgeocodeReq { | ||
@@ -5,0 +5,0 @@ location: Coordinates; |
@@ -1,4 +0,4 @@ | ||
import OneMap from '..'; | ||
import { OneMap } from '../OneMap'; | ||
import { ApiRes } from '../types'; | ||
import { Service } from '.'; | ||
import { ApiRes } from '../types'; | ||
export interface LatLonReq { | ||
@@ -5,0 +5,0 @@ latitude: number; |
@@ -1,4 +0,4 @@ | ||
import OneMap from '..'; | ||
import { OneMap } from '../OneMap'; | ||
import { ApiRes } from '../types'; | ||
import { Service } from '.'; | ||
import { ApiRes } from '../types'; | ||
export interface GetAllPlanningareaReq { | ||
@@ -5,0 +5,0 @@ year: number; |
@@ -1,4 +0,4 @@ | ||
import OneMap from '..'; | ||
import { OneMap } from '../OneMap'; | ||
import { ApiRes } from '../types'; | ||
import { Service } from '.'; | ||
import { ApiRes } from '../types'; | ||
export interface PopulationReq { | ||
@@ -5,0 +5,0 @@ year: number; |
@@ -1,4 +0,4 @@ | ||
import OneMap from '..'; | ||
import { OneMap } from '../OneMap'; | ||
import { Coordinates, ApiRes } from '../types'; | ||
import { Service } from '.'; | ||
import { Coordinates, ApiRes } from '../types'; | ||
export interface RouteReq { | ||
@@ -5,0 +5,0 @@ start: Coordinates; |
@@ -1,4 +0,4 @@ | ||
import OneMap from '..'; | ||
import { OneMap } from '../OneMap'; | ||
import { ApiRes } from '../types'; | ||
import { Service } from '.'; | ||
import { ApiRes } from '../types'; | ||
export interface SearchReq { | ||
@@ -5,0 +5,0 @@ searchVal: string; |
@@ -1,2 +0,2 @@ | ||
import OneMap from '..'; | ||
import { OneMap } from '../OneMap'; | ||
export declare class Service { | ||
@@ -3,0 +3,0 @@ #private; |
@@ -28,5 +28,5 @@ "use strict"; | ||
exports.Service = void 0; | ||
const querystring_1 = __importDefault(require("querystring")); | ||
const axios_1 = __importDefault(require("axios")); | ||
const querystring_1 = __importDefault(require("querystring")); | ||
const __1 = __importDefault(require("..")); | ||
const OneMap_1 = require("../OneMap"); | ||
class Service { | ||
@@ -70,3 +70,3 @@ constructor(onemap, serviceName) { | ||
} | ||
return `${__1.default.BASE_URL}/${type}/${__classPrivateFieldGet(this, _Service_serviceName, "f")}/${endpoint}`; | ||
return `${OneMap_1.OneMap.BASE_URL}/${type}/${__classPrivateFieldGet(this, _Service_serviceName, "f")}/${endpoint}`; | ||
}, _Service_fetch = function _Service_fetch(type, endpoint, query) { | ||
@@ -73,0 +73,0 @@ var _a; |
@@ -1,4 +0,4 @@ | ||
import OneMap from '..'; | ||
import { OneMap } from '../OneMap'; | ||
import { Coordinates, Color } from '../types'; | ||
import { Service } from '.'; | ||
import { Coordinates, Color } from '../types'; | ||
export interface GetStaticImageUriReq { | ||
@@ -5,0 +5,0 @@ layerchosen: 'night' | 'grey' | 'original' | 'default' | 'landlot'; |
@@ -1,4 +0,4 @@ | ||
import OneMap from '..'; | ||
import { OneMap } from '../OneMap'; | ||
import { Coordinates, ApiRes } from '../types'; | ||
import { Service } from '.'; | ||
import { Coordinates, ApiRes } from '../types'; | ||
export interface CheckThemeStatusReq { | ||
@@ -5,0 +5,0 @@ queryName: string; |
{ | ||
"name": "onemapsg", | ||
"version": "1.0.3", | ||
"version": "1.1.0", | ||
"author": "Chang Zhe Jiet", | ||
@@ -42,2 +42,3 @@ "description": "Helper library for using OneMap APIs.", | ||
"eslint-plugin-import": "^2.23.4", | ||
"eslint-plugin-security": "^1.4.0", | ||
"jest": "^27.0.3", | ||
@@ -44,0 +45,0 @@ "ts-jest": "^27.0.1", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
44104
11
1127