Skip to content

Commit 8f862a9

Browse files
authored
fix(deno): Emit .mjs files (#9485)
1 parent 62e562e commit 8f862a9

File tree

4 files changed

+4
-5
lines changed

4 files changed

+4
-5
lines changed

packages/deno/package.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66
"homepage": "https://github.com/getsentry/sentry-javascript/tree/master/packages/deno",
77
"author": "Sentry",
88
"license": "MIT",
9-
"main": "build/index.js",
109
"module": "build/index.js",
1110
"types": "build/index.d.ts",
1211
"publishConfig": {
@@ -51,7 +50,7 @@
5150
"pretest": "run-s deno-types test:build",
5251
"test": "run-s install:deno test:types test:unit",
5352
"test:build": "tsc -p tsconfig.test.types.json && rollup -c rollup.test.config.js",
54-
"test:types": "deno check ./build/index.js",
53+
"test:types": "deno check ./build/index.mjs",
5554
"test:unit": "deno test --allow-read --allow-run",
5655
"test:unit:update": "deno test --allow-read --allow-write --allow-run -- --update",
5756
"yalc:publish": "ts-node ../../scripts/prepack.ts && yalc publish build --push"

packages/deno/rollup.config.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ export default defineConfig({
77
input: ['src/index.ts'],
88
treeshake: 'smallest',
99
output: {
10-
dir: 'build',
10+
file: 'build/index.mjs',
1111
sourcemap: true,
1212
preserveModules: false,
1313
strict: false,

packages/deno/test/example.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import * as Sentry from '../build/index.js';
1+
import * as Sentry from '../build/index.mjs';
22

33
Sentry.init({
44
dsn: 'https://[email protected]/4505526893805568',

packages/deno/test/mod.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { assertSnapshot } from 'https://deno.land/[email protected]/testing/snapshot.t
33

44
import type { sentryTypes } from '../build-test/index.js';
55
import { sentryUtils } from '../build-test/index.js';
6-
import { defaultIntegrations, DenoClient, Hub, Scope } from '../build/index.js';
6+
import { defaultIntegrations, DenoClient, Hub, Scope } from '../build/index.mjs';
77
import { getNormalizedEvent } from './normalize.ts';
88
import { makeTestTransport } from './transport.ts';
99

0 commit comments

Comments
 (0)