Skip to content

Commit

Permalink
feat(ember): Update ember dependencies
Browse files Browse the repository at this point in the history
This updates the versions of some dependencies for the Ember SDK:

* `ember-auto-import` is bumped to `^2.4.3`
* `ember-cli-babel` is bumped to `^8.2.0`
* `ember-cli-typescript` is bumped to `^5.3.0`

add migration entry

bump more stuff??

fix check?

dedupe embroider versions

fix stuff...?

remove unneeded package

add regenerator??
  • Loading branch information
mydea committed Apr 29, 2024
1 parent d5cafe5 commit 28e38c5
Show file tree
Hide file tree
Showing 6 changed files with 913 additions and 123 deletions.
9 changes: 9 additions & 0 deletions MIGRATION.md
Original file line number Diff line number Diff line change
Expand Up @@ -958,12 +958,21 @@ replacement API.
Removed top-level exports: `InitSentryForEmber`, `StartTransactionFunction`
- [Removal of `InitSentryForEmber` export](./MIGRATION.md#removal-of-initsentryforember-export)
- [Updated Ember Dependencies](./MIGRATION.md#updated-ember-dependencies)
#### Removal of `InitSentryForEmber` export
The `InitSentryForEmber` export has been removed. Instead, you should use the `Sentry.init` method to initialize the
SDK.
#### Updated Ember Dependencies
The following dependencies that the SDK uses have been bumped to a more recent version:
- `ember-auto-import` is bumped to `^2.4.3`
- `ember-cli-babel` is bumped to `^8.2.0`
- `ember-cli-typescript` is bumped to `^5.3.0`
### Svelte SDK
Removed top-level exports: `componentTrackingPreprocessor`
Expand Down
15 changes: 8 additions & 7 deletions packages/ember/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,26 +25,27 @@
"lint:ts": "tsc",
"fix": "eslint . --format stylish --fix",
"start": "ember serve",
"test": "ember b --prod && ember test",
"test": "ember b --prod && yarn ember test",
"test:all": "ember try:each",
"prepack": "ember ts:precompile",
"postpack": "ember ts:clean"
},
"dependencies": {
"@embroider/macros": "^1.9.0",
"@babel/core": "^7.24.4",
"@embroider/macros": "^1.16.0",
"@sentry/browser": "8.0.0-beta.4",
"@sentry/core": "8.0.0-beta.4",
"@sentry/types": "8.0.0-beta.4",
"@sentry/utils": "8.0.0-beta.4",
"ember-auto-import": "^1.12.1 || ^2.4.3",
"ember-cli-babel": "^7.26.11",
"ember-auto-import": "^2.7.2",
"ember-cli-babel": "^8.2.0",
"ember-cli-htmlbars": "^6.1.1",
"ember-cli-typescript": "^5.1.1"
"ember-cli-typescript": "^5.3.0"
},
"devDependencies": {
"@ember/optional-features": "~1.3.0",
"@ember/test-helpers": "2.9.4",
"@embroider/test-setup": "~1.8.3",
"@embroider/test-setup": "~4.0.0",
"@glimmer/component": "~1.1.2",
"@glimmer/tracking": "~1.1.2",
"@types/ember": "~3.16.5",
Expand All @@ -62,8 +63,8 @@
"ember-cli-terser": "~4.0.2",
"ember-cli-typescript-blueprints": "~3.0.0",
"ember-disable-prototype-extensions": "~1.1.3",
"ember-maybe-import-regenerator": "1.0.0",
"ember-load-initializers": "~2.1.1",
"ember-maybe-import-regenerator": "~1.0.0",
"ember-qunit": "~6.0.0",
"ember-resolver": "11.0.0",
"ember-sinon-qunit": "7.1.4",
Expand Down
5 changes: 2 additions & 3 deletions packages/ember/tests/dummy/app/controllers/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import Controller from '@ember/controller';
import EmberError from '@ember/error';
import { action } from '@ember/object';
import { scheduleOnce } from '@ember/runloop';
import { tracked } from '@glimmer/tracking';
Expand All @@ -16,13 +15,13 @@ export default class IndexController extends Controller {

@action
public createEmberError(): void {
throw new EmberError('Whoops, looks like you have an EmberError');
throw new Error('Whoops, looks like you have an EmberError');
}

@action
public createCaughtEmberError(): void {
try {
throw new EmberError('Looks like you have a caught EmberError');
throw new Error('Looks like you have a caught EmberError');
} catch (e) {
// do nothing
}
Expand Down
3 changes: 2 additions & 1 deletion packages/ember/tests/dummy/app/initializers/deprecation.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@ export function initialize(): void {
if (options && options.until && options.until !== '3.0.0') {
return;
} else {
// @ts-expect-error this is fine
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
// @ts-ignore In some versions this exists, in others not - so we also can't use `@ts-expect-error` here
next(message, options);
}
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,15 +17,15 @@ module('Unit | Utility | instrument-route-performance', function (hooks) {
const setupController = sinon.spy();

class DummyRoute extends Route {
public beforeModel(...args: unknown[]): unknown {
public beforeModel(...args: unknown[]): ReturnType<Route['beforeModel']> {
return beforeModel.call(this, ...args);
}

public model(...args: unknown[]): unknown {
return model.call(this, ...args);
}

public afterModel(...args: unknown[]): unknown {
public afterModel(...args: unknown[]): ReturnType<Route['afterModel']> {
return afterModel.call(this, ...args);
}

Expand Down
Loading

0 comments on commit 28e38c5

Please sign in to comment.