Skip to content

Commit 3b988d4

Browse files
Merge pull request #74 from universal-ember/fix-types
Fix types
2 parents b2b7010 + 4596844 commit 3b988d4

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

src/browser/virtual/setup.d.ts

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,13 @@
11
import type { Manifest } from '@universal-ember/kolay-ui';
22

3+
interface ResolveMap {
4+
[moduleName: string]: ScopeMap;
5+
}
6+
7+
interface ScopeMap {
8+
[identifier: string]: unknown;
9+
}
10+
311
export function setupKolay(
412
context: object,
513
options?: {
@@ -14,15 +22,15 @@ export function setupKolay(
1422
* - <APIDocs>
1523
* - <ComponentSignature>
1624
*/
17-
topLevelScope?: Record<string, unknown>;
25+
topLevelScope?: ScopeMap;
1826

1927
/**
2028
* Additional modules you'd like to be able to import from.
2129
* This is in addition the the default modules provided by ember,
2230
* and allows you to have access to private libraries without
2331
* needing to publish those libraries to NPM.
2432
*/
25-
resolve?: Record<string, Record<string, unknown>>;
33+
resolve?: { [moduleName: string]: Promise<ScopeMap> };
2634

2735
/**
2836
* Provide additional remark plugins to the default markdown compiler.

ui/src/router.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import type { RouterDSL } from '@ember/-internals/routing';
22

3-
export function addRoutes(context: RouterDSL): void {
3+
export function addRoutes(context: Pick<RouterDSL, 'route'>): void {
44
/**
55
* We need a level of nesting for every `/` in the URL so that we don't over-refresh / render the whole page
66
*/

0 commit comments

Comments
 (0)