Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUGFIX LTS] Backport more types fixes #20493

Merged
merged 1 commit into from
Jun 30, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@
"@babel/helper-module-imports": "^7.16.7",
"@babel/plugin-transform-block-scoping": "^7.20.5",
"@ember/edition-utils": "^1.2.0",
"@simple-dom/interface": "^1.4.0",
"@glimmer/vm-babel-plugins": "0.84.2",
"babel-plugin-debug-macros": "^0.3.4",
"babel-plugin-filter-imports": "^4.0.0",
Expand Down
12 changes: 4 additions & 8 deletions types/preview/@ember/application/index.d.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,12 @@
declare module '@ember/application' {
import Engine from '@ember/engine';
import ApplicationInstance from '@ember/application/instance';
import ApplicationInstance, { BootOptions } from '@ember/application/instance';
import EventDispatcher from '@ember/application/-private/event-dispatcher';
import { EventDispatcherEvents } from '@ember/application/types';
import Router from '@ember/routing/router';
import Registry from '@ember/application/-private/registry';
import { AnyFn } from 'ember/-private/type-utils';
import Owner, { Resolver } from '@ember/owner';
import type GlimmerComponent from '@glimmer/component';
import EmberObject from '@ember/object';
import Owner from '@ember/owner';

// Shut off default exporting; we don't want anything but the *intended*
// public API present.
Expand Down Expand Up @@ -82,10 +80,6 @@ declare module '@ember/application' {
* The Ember.EventDispatcher responsible for delegating events to this application's views.
*/
eventDispatcher: EventDispatcher;
/**
* Set this to provide an alternate class to `DefaultResolver`
*/
resolver: Resolver | null;
/**
* The root DOM element of the Application. This can be specified as an
* element or a jQuery-compatible selector string.
Expand Down Expand Up @@ -114,6 +108,8 @@ declare module '@ember/application' {
* Create an ApplicationInstance for this Application.
*/
buildInstance(options?: object): ApplicationInstance;

visit(url: string, options: BootOptions): Promise<ApplicationInstance>;
}

/**
Expand Down
12 changes: 12 additions & 0 deletions types/preview/@ember/application/instance.d.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
declare module '@ember/application/instance' {
import EngineInstance from '@ember/engine/instance';
import { SimpleElement } from '@simple-dom/interface';

export interface BootOptions {
isBrowser?: boolean;
shouldRender?: boolean;
document?: Document | null;
rootElement?: string | Element | SimpleElement | null;
location?: string | null;
// Private?
isInteractive?: boolean;
_renderMode?: string;
}

/**
* The `ApplicationInstance` encapsulates all of the stateful aspects of a
Expand Down