Skip to content

Commit b2af13c

Browse files
fix: remove import map
Doesn't work with importing in deno
1 parent 51af82e commit b2af13c

File tree

8 files changed

+16
-19
lines changed

8 files changed

+16
-19
lines changed

deno.jsonc

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,5 @@
22
"tasks": {
33
"npm": "deno run -A scripts/build_npm.ts"
44
},
5-
"exclude": ["npm"],
6-
"imports": {
7-
"~/": "./"
8-
}
5+
"exclude": ["npm"]
96
}

mod.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
export * from "~/src/core/studentClient.ts";
2-
export * from "~/src/core/parentClient.ts";
1+
export * from "./src/core/studentClient.ts";
2+
export * from "./src/core/parentClient.ts";

src/core/baseClient.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ import type {
1717
LessonsResponse,
1818
PupilFieldsResponse,
1919
} from "../types.ts";
20-
import { PING_INTERVAL } from "~/src/utils/consts.ts";
20+
import { PING_INTERVAL } from "../utils/consts.ts";
2121

2222
/**
2323
* Shared client for both parent and student. This is not exported and should not be used directly

src/core/parentClient.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
import type { GetPupilsResponse } from "../types.ts";
22

3-
import { BaseClient } from "~/src/core/baseClient.ts";
4-
import { API_BASE_PARENT, BASE_URL } from "~/src/utils/consts.ts";
5-
import { parseCookies } from "~/src/utils/utils.ts";
3+
import { BaseClient } from "../core/baseClient.ts";
4+
import { API_BASE_PARENT, BASE_URL } from "../utils/consts.ts";
5+
import { parseCookies } from "../utils/utils.ts";
66
/**
77
* Parent Client
88
*/

src/core/parentClient_test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import { assertRejects } from "~/deps_dev.ts";
2-
import { ParentClient } from "~/src/core/parentClient.ts";
1+
import { assertRejects } from "../../deps_dev.ts";
2+
import { ParentClient } from "../core/parentClient.ts";
33

44
Deno.test("Throws when no email is provided", async () => {
55
const client = new ParentClient("", "password");

src/core/studentClient.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
import { API_BASE_STUDENT, BASE_URL } from "~/src/utils/consts.ts";
2-
import { BaseClient } from "~/src/core/baseClient.ts";
3-
import { parseCookies } from "~/src/utils/utils.ts";
4-
import { RewardPurchaseResponse, RewardsResponse } from "~/src/types.ts";
1+
import { API_BASE_STUDENT, BASE_URL } from "../utils/consts.ts";
2+
import { BaseClient } from "../core/baseClient.ts";
3+
import { parseCookies } from "../utils/utils.ts";
4+
import { RewardPurchaseResponse, RewardsResponse } from "../types.ts";
55

66
/**
77
* Student Client

src/core/studentClient_test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
import { assertRejects } from "~/deps_dev.ts";
2-
import { StudentClient } from "~/src/core/studentClient.ts";
1+
import { assertRejects } from "../../deps_dev.ts";
2+
import { StudentClient } from "../core/studentClient.ts";
33

44
Deno.test("Throws when no student code is provided", async () => {
55
const client = new StudentClient("");

src/utils/utils_test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { assertEquals, assertExists } from "~/deps_dev.ts";
1+
import { assertEquals, assertExists } from "../../deps_dev.ts";
22
import { parseCookies } from "./utils.ts";
33
Deno.test("Parses simple cookie", () => {
44
const cookie =

0 commit comments

Comments
 (0)