update to new url
This commit is contained in:
parent
617edf8250
commit
029586a6f6
4 changed files with 9 additions and 8 deletions
3
.gitignore
vendored
3
.gitignore
vendored
|
@ -1,2 +1,3 @@
|
|||
node_modules
|
||||
dist
|
||||
dist
|
||||
.DS_Store
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
# JavaScript SDK for Aptabase
|
||||
|
||||
A tiny SDK (1 kB) to instrument your web app with Aptabase, a privacy-first analytics platform for desktop, mobile and web apps.
|
||||
A tiny SDK (1 kB) to instrument your web app with Aptabase, an Open Source, Privacy-First and Simple Analytics for Mobile, Desktop and Web Apps.
|
||||
|
||||
> 👉 **IMPORTANT**
|
||||
>
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
{
|
||||
"name": "@aptabase/web",
|
||||
"version": "0.0.2",
|
||||
"version": "0.0.3",
|
||||
"private": false,
|
||||
"description": "JavaScript SDK for Aptabase: Privacy-first and simple analytics for apps",
|
||||
"description": "JavaScript SDK for Aptabase: Open Source, Privacy-First and Simple Analytics for Mobile, Desktop and Web Apps",
|
||||
"browser": "dist/index.js",
|
||||
"main": "dist/index.js",
|
||||
"types": "dist/index.d.ts",
|
||||
|
|
|
@ -14,9 +14,9 @@ let _sessionId = newSessionId();
|
|||
let _options: AptabaseOptions | undefined;
|
||||
|
||||
const regions: { [region: string]: string } = {
|
||||
US: "https://api-us.aptabase.com",
|
||||
EU: "https://api-eu.aptabase.com",
|
||||
DEV: "http://localhost:5251",
|
||||
US: "https://us.aptabase.com",
|
||||
EU: "https://eu.aptabase.com",
|
||||
DEV: "http://localhost:3000",
|
||||
};
|
||||
|
||||
export function init(appKey: string, options?: AptabaseOptions) {
|
||||
|
@ -33,7 +33,7 @@ export function init(appKey: string, options?: AptabaseOptions) {
|
|||
|
||||
const region = parts[1];
|
||||
const baseUrl = regions[region] ?? regions.DEV;
|
||||
_apiUrl = `${baseUrl}/v0/event`;
|
||||
_apiUrl = `${baseUrl}/api/v0/event`;
|
||||
|
||||
_locale =
|
||||
navigator.languages && navigator.languages.length
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue