Why do TSLint and JSLint report empty blocks?

From time to time, I get TSLint errors "block is empty". This happens e.g. when I pass a no-op callback to a function: doSomething(() => {}); From what I read, JSLint apparently does the same,...

Can't import CSS/SCSS modules. TypeScript says "Cannot Find Module"

I'm trying to import a theme from a CSS module but TypeScript gives me a "Cannot Find Module" error and the theme isn't applied on runtime. I think there's something wrong with my Webpack config...

In Typescript, what is the ! (exclamation mark / bang) operator when dereferencing a member?

When looking at the sourcecode for a tslint rule, I came across the following statement: if (node.parent!.kind === ts.SyntaxKind.ObjectLiteralExpression) { return; } Notice the ! operator...

Angular No module factory available for dependency type: ContextElementDependency

Running ng build on my Angular 4 project give this error : 14% building modules 40/46 modules 6 active ...es\@angular\http\@angular\http.es5.js An error occured during the build: Error: No...

Docker build image - glob error { Error: EPERM: operation not permitted, scandir

I'm attempting to build a Docker image of a React+TypeScript+NodeJS application built with Webpack 2.0, but I get the following error > [email protected] build / > webpack -p --config...

Error: No provider for t

I am trying to compile my angular code to production mode via ng build --prod and its successful but in browser I get the error : ERROR p {__zone_symbol__error: Error: Uncaught (in promise):...

tslint how to disable error "someVariable is declared but its value is never read"

I'm using tslint, and got the error. 'myVariable' is declared but its value is never read. I went to the website that documents the rules https://palantir.github.io/tslint/rules/ and searched...

Angular 6 Update - rxjs-5-to-6-migrate command not found

In the upgrade process from update.angular.io: Remove deprecated RxJS 6 features using rxjs-tslint auto update rules. For most applications this will mean running the following two commands: ...

Could not find module "@angular-devkit/build-angular"

After updating to Angular 6.0.1, I get the following error on ng serve: Could not find module "@angular-devkit/build-angular" from "/home/Projects/myProjectName". Error: Could not find module...

Modules not found when using express

I want to expose REST service in electron app and I want to use expressJS with electron, as tutorial states I added express and @types/express. I tried to expose a "get " but when I build and run...

"Unknown word" error showing after adding postcss-loader

I am trying to add postcss loader in my webpack but after adding postcss loader showing Unknown word error. I also attached error screenshot. please find attachment. Not sure what error is.... I...

Asp.Net Core Angular 6 Error : The NPM script 'start' exited without indicating that the Angular CLI was listening for requests

#Problem I create asp.net core with angular 6 application in visual studio 2017 and application is working locally perfectly fine. but when I tried to deploy it to cloud it shows me this...

TypeScript error TS2403: Subsequent variable declarations must have the same type

I seem to be running into some compile errors on my TypeScript project. The full error is: node_modules/@types/mocha/index.d.ts:2680:13 - error TS2403: Subsequent variable declarations must have...

Cannot find name 'it' in Jest TypeScript

I try to create an intial setup for Jest in React + TypeScript. I have completed the initial setup and try to check whether the test runs. When I run the test using the command npm test, I am...

Disabling tslint for a block of code with tslint:disable does not work

I'm trying to disable TSlint (Version: typescript 3.5.2, tslint 5.18.0) for a block of code in a VueJS project but it doesn't seems to work (it still displays errors and warning for this block at...

Typescript: compilation errors when updating Firebase function dependencies

I tried to update the dependencies of my Firebase functions project to use more recent versions of firebase-functions and firebase-admin, which in turn seemed to required more recent versions of...

Ng serve throwing @angular/core/core has no exported member 'eeFactoryDef'

Im getting like 50 errors that all say that angular/core/core has no exported member 'eeFactoryDef'. They come from different node_modules, for example angular/cdk, ng-bootstrap, ngx-pipes,...

Uncaught TypeError: Cannot read property 'id' of undefined at registerNgModuleType - angular PWA

after adding @angular/pwa to my app ng add @angular/pwa --project appName I get error core.js:34469 Uncaught TypeError: Cannot read property 'id' of undefined at registerNgModuleType If I in...

Eslint not working with the TypeScript syntax

I am trying to configure eslint for my REACT-TypeScript project. It was previously using tslint which is going to deprecate soon. I have gone through the web and finally was able to create my...

VS Code 2017 F12 or Crtl Click Goto Definition not working, Angular 7.3.9

I am a beginner writing in Angular 7.3.9 I really need to use the the f12 function or ctrl right click to go to the definition. Currently it is not working. I am trying to uninstall and reinstall...

npm ERR! 404 Not Found - GET https://registry.npmjs.org/error-ex

I am trying to install npm package dependencies in to my angular application and i am getting this error. Any help to fix this? npm ERR! code E404 npm ERR! 404 Not Found: [email protected]^1.2.0 npm ERR!...

VSCode needs to be restarted after modifying tsconfig and tslint files in nrwl nx projects to eliminate errors

I'm working on a project with Nrwl nx in VSCode and whenever I change a route to a library or the prefix for a library my code shows a bunch of false errors. Everything still renders as expected...

Heroku deployment of Node application returns node-waf: not found

I am attempting to deploy my Node.js application to Heroku by connecting Heroku to my Github repository and deploying the master branch. I have tried a number of different approaches to deploy my...

Angular npm install works but npm ci gives errors

i've got an issue where I have an ASP.NET core app that hosts an Angular application. running npm install works fine, however npm ci does not work and gives the following errors: Error: npm WARN...

Angular TSLint: Only allow camelCase, do Not allow Pascal case

We are writing code in Angular, and only want to allow lower-case first letter, Camel case. For example, ProductName should show a display warning/error (since its capitalized). How can I allow...

Difference between ESLint and TSLint

I searched for many articles about this question. I couldn't find any article related to that. Can some tell me what are the cons of Eslint over TsLint. Why do we have to move to ESLint?

eslint register custom prefix for angular library: the selector should start with one of these prefixes,

I have an Angular 12 solution that has two projects: one that is a library and one that is an app. I converted these from using tslint to eslint. I used the following commands: ng add...

NOT SUPPORTED: keyword "id", use "$id" for schema ID : TSLint (ng add @angular-eslint/schematics)

I am upgrading my Angular 10 application to Angular 13. I did well with other compatibilities of dependencies. The project is compiling and working fine. Now the time for TSLint I tried to update...

Angular TSLint - Cannot find builder "@angular-devkit/build-angular:tslint"

When I try to run command ng lint --fix cli throws this error: An unhandled exception occurred: Cannot find builder "@angular-devkit/build-angular:tslint". See...

npm ERESOLVE unable to resolve dependency tree NestJs Passport

I have following package.json { "dependencies": { "@elastic/elasticsearch": "^7.16.0", "@nestjs/common": "^8.2.4", "@nestjs/config": "^1.1.5", "@nestjs/core": "^8.2.4", ...