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

build(deps-dev): bump typescript from 4.7.4 to 4.9.4 #245

Merged
merged 4 commits into from
Dec 10, 2022
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.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
49 changes: 25 additions & 24 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -47,34 +47,35 @@
"dependencies": {
"ember-cli-babel": "^7.26.11",
"ember-cli-htmlbars": "^6.0.1",
"ember-cli-typescript": "^5.1.0"
"ember-cli-typescript": "^5.2.1"
},
"devDependencies": {
"@ember/optional-features": "^2.0.0",
"@ember/test-helpers": "^2.7.0",
"@embroider/test-setup": "^1.6.0",
"@types/ember": "^4.0.0",
"@types/ember-qunit": "^5.0.0",
"@types/ember-resolver": "^5.0.11",
"@types/ember__application": "^4.0.0",
"@types/ember__array": "^4.0.1",
"@types/ember__component": "^4.0.8",
"@types/ember__controller": "^4.0.0",
"@types/ember__debug": "^4.0.1",
"@types/ember__engine": "^4.0.0",
"@types/ember__error": "^4.0.0",
"@types/ember__object": "^4.0.2",
"@types/ember__polyfills": "^4.0.0",
"@types/ember__routing": "^4.0.7",
"@types/ember__runloop": "^4.0.1",
"@types/ember__service": "^4.0.0",
"@types/ember__string": "^3.0.9",
"@types/ember__template": "^4.0.0",
"@types/ember__test": "^4.0.0",
"@types/ember__test-helpers": "^2.6.1",
"@types/ember__utils": "^4.0.0",
"@types/htmlbars-inline-precompile": "^3.0.0",
"@types/qunit": "^2.19.1",
"@tsconfig/ember": "^1.1.0",
"@types/ember": "^4.0.3",
"@types/ember-qunit": "^5.0.2",
"@types/ember-resolver": "^5.0.13",
"@types/ember__application": "^4.0.5",
"@types/ember__array": "^4.0.3",
"@types/ember__component": "^4.0.11",
"@types/ember__controller": "^4.0.4",
"@types/ember__debug": "^4.0.3",
"@types/ember__destroyable": "^4.0.1",
"@types/ember__engine": "^4.0.4",
"@types/ember__error": "^4.0.2",
"@types/ember__object": "^4.0.5",
"@types/ember__polyfills": "^4.0.1",
"@types/ember__routing": "^4.0.12",
"@types/ember__runloop": "^4.0.2",
"@types/ember__service": "^4.0.1",
"@types/ember__string": "^3.0.10",
"@types/ember__template": "^4.0.1",
"@types/ember__test": "^4.0.1",
"@types/ember__test-helpers": "^2.8.2",
"@types/ember__utils": "^4.0.2",
"@types/qunit": "^2.19.3",
"@types/rsvp": "^4.0.4",
"@typescript-eslint/eslint-plugin": "^4.30.0",
"@typescript-eslint/parser": "^4.30.0",
Expand All @@ -101,7 +102,7 @@
"npm-run-all": "^4.1.5",
"qunit": "^2.19.1",
"qunit-dom": "^2.0.0",
"typescript": "^4.7.4",
"typescript": "^4.9.4",
"webpack": "^5.74.0"
},
"engines": {
Expand Down
4 changes: 2 additions & 2 deletions tests/dummy/app/config/environment.d.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
export default config

/**
* Type declarations for
* import config from 'my-app/config/environment'
Expand All @@ -12,3 +10,5 @@ declare const config: {
rootURL: string
APP: Record<string, unknown>
}

export default config
64 changes: 3 additions & 61 deletions tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,68 +1,9 @@
{
"extends": "@tsconfig/ember/tsconfig.json",
"compilerOptions": {
"target": "ES2021",
"module": "ES2020",
"moduleResolution": "node",

// Trying to check Ember apps and addons with `allowJs: true` is a recipe
// for many unresolveable type errors, because with *considerable* extra
// configuration it ends up including many files which are *not* valid and
// cannot be: they *appear* to be resolve-able to TS, but are in fact not in
// valid Node-resolveable locations and may not have TS-ready types. This
// will likely improve over time
"allowJs": false,

// --- TS for SemVer Types compatibility
// Strictness settings -- you should *not* change these: Ember code is not
// guaranteed to type check with these set to looser values.
"strict": true,
"noUncheckedIndexedAccess": true,

// Interop: these are viral and will require anyone downstream of your
// package to *also* set them to true. If you *must* enable them to consume
// an upstream package, you should document that for downstream consumers to
// be aware of.
//
// These *are* safe for apps to enable, since they do not *have* downstream
// consumers; but leaving them off is still preferred when possible, since
// it makes it easier to switch between apps and addons and have the same
// rules for what can be imported and how.
"allowSyntheticDefaultImports": false,
"esModuleInterop": false,

// --- Lint-style rules

// TypeScript also supplies some lint-style checks; nearly all of them are
// better handled by ESLint with the `@typescript-eslint`. This one is more
// like a safety check, though, so we leave it on.
"noPropertyAccessFromIndexSignature": true,

// --- Compilation/integration settings
// Setting `noEmitOnError` here allows ember-cli-typescript to catch errors
// and inject them into Ember CLI's build error reporting, which provides
// nice feedback for when
"noEmitOnError": true,

// We use Babel for emitting runtime code, because it's very important that
// we always and only use the same transpiler for non-stable features, in
// particular decorators. If you were to change this to `true`, it could
// lead to accidentally generating code with `tsc` instead of Babel, and
// could thereby result in broken code at runtime.
"noEmit": true,

// Ember makes heavy use of decorators; TS does not support them at all
// without this flag.
"experimentalDecorators": true,

// Support generation of source maps. Note: you must *also* enable source
// maps in your `ember-cli-babel` config and/or `babel.config.js`.
"declaration": true,
"declarationMap": true,
"inlineSourceMap": true,
"inlineSources": true,

// The combination of `baseUrl` with `paths` allows Ember's classic package
// layout, which is not resolveable with the Node resolution algorithm, to
// layout, which is not resolvable with the Node resolution algorithm, to
// work with TypeScript.
"baseUrl": ".",

Expand All @@ -83,6 +24,7 @@

// https://www.typescriptlang.org/tsconfig#noUnusedParameters
"noUnusedParameters": true,

"paths": {
"dummy/tests/*": [
"tests/*"
Expand Down
3 changes: 2 additions & 1 deletion types/global.d.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
// Types for compiled templates
declare module 'ember-cli-embedded/templates/*' {
import { TemplateFactory } from 'htmlbars-inline-precompile'
import { TemplateFactory } from 'ember-cli-htmlbars'

const tmpl: TemplateFactory
export default tmpl
}
Loading