Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
mjamin
@mjamin

´strictMetadataEmit´ is a flag for libraries, which shouldn't have any lazy loaded modules at all.
https://github.com/angular/angular/issues/31893#issuecomment-516615243

Can anyone elaborate why libraries shouldn't have lazy loaded modules? We're building an application platform and were planning to split features into various npm packages in a private npm registry for our inhouse devs and partners to install into their concrete project application as needed. We were hoping they could just import @company/feature-module into their angular app and have everything wired up automatically, including the (lazy-loaded) routing.

JuanCarlosJr97
@juancarlosjr97
Is it possible to extract the date from the matDatepicker wihtout getting access to the date object?
JuanCarlosJr97
@juancarlosjr97
I did it guys, thank you!
JuanCarlosJr97
@juancarlosjr97
nextQuestion() {
    let currentQuestion = `Q${this.questionCounter}`;
    this.listOfQuestions.currentQuestion[0].status
    console.log(currentQuestion);
    this.questionCounter++;
    let nextQuestion = `Q${this.questionCounter}`;
    // console.log();

  }
It is possible to use currentQuestion to call a specific question???
JuanCarlosJr97
@juancarlosjr97
I solved it, thank you guys!
Ron Fogel
@ronfogel
Hey Guys, is there any progress/update regarding ng update not working properly?
JuanCarlosJr97
@juancarlosjr97
Does anyone knows which is directive to ng change in angular 7?
rvalimaki
@rvalimaki

Am I the only one to experience very frequent false aot re-build errors looking like below? They happen to point to very random LESS-files, which usually, as in this case were not modified at all, or even those components any way related to them were not modified.

These never occur on the first clean build, but only when using ng serve --aot and making some modifications to the code. Also no matter what modifications you do, those false errors never go away until you kill ng serve and start another one. Pretty frustrating. I'm wondering if this has something to do with code maps, which are for us pretty useless regarding LESS files anyway.

ERROR in ./src/app/shared/views/cleaningMode/cleaningMode.less.shim.ngstyle.js
Module build failed (from ./node_modules/@ngtools/webpack/src/index.js):
Error: ENOENT: no such file or directory, open 'C:\PATH\TO\src\app\shared\views\cleaningMode\cleaningMode.less.shim.ngstyle.js'
    at Object.openSync (fs.js:447:3)
    at Object.readFileSync (fs.js:349:35)
    at Storage.provideSync (C:\PATH\TO\node_modules\enhanced-resolve\lib\CachedInputFileSystem.js:98:13)
    at CachedInputFileSystem.readFileSync (C:\PATH\TO\node_modules\enhanced-resolve\lib\CachedInputFileSystem.js:259:32)
    at Observable._subscribe (C:\PATH\TO\node_modules\@ngtools\webpack\src\webpack-input-host.js:35:51)
    at Observable._trySubscribe (C:\PATH\TO\node_modules\@ngtools\webpack\node_modules\rxjs\internal\Observable.js:44:25)
    at Observable.subscribe (C:\PATH\TO\node_modules\@ngtools\webpack\node_modules\rxjs\internal\Observable.js:30:22)
    at SyncDelegateHost._doSyncCall (C:\PATH\TO\node_modules\@angular-devkit\core\src\virtual-fs\host\sync.js:22:20)
    at SyncDelegateHost.read (C:\PATH\TO\node_modules\@angular-devkit\core\src\virtual-fs\host\sync.js:49:21)
    at WebpackCompilerHost.readFileBuffer (C:\PATH\TO\node_modules\@ngtools\webpack\src\compiler_host.js:147:44)
    at VirtualFileSystemDecorator.readFile (C:\PATH\TO\node_modules\@ngtools\webpack\src\virtual_file_system_decorator.js:42:54)
    at processResource (C:\PATH\TO\node_modules\loader-runner\lib\LoaderRunner.js:202:11)
    at iteratePitchingLoaders (C:\PATH\TO\node_modules\loader-runner\lib\LoaderRunner.js:158:10)
    at iteratePitchingLoaders (C:\PATH\TO\node_modules\loader-runner\lib\LoaderRunner.js:165:10)
    at C:\PATH\TO\node_modules\loader-runner\lib\LoaderRunner.js:176:18
    at loadLoader (C:\PATH\TO\node_modules\loader-runner\lib\loadLoader.js:47:3)
rvalimaki
@rvalimaki
I tried to disable source maps for styles, but that didn't help the situation
JuanCarlosJr97
@juancarlosjr97
How can I acces a form control???
Alibra
@thedubb

Hi all! I have an Angular Elements question for someone. In my component, i’m trying to simply access the variable passed into my angular element web component. The rendering of the tag seems to be fine, but the data I’m trying to pass doesn’t appear to enter my component. I have my component:

<my-component count=“0”></my-component>

inside of my component .ts file:

@Input() count: number;

my actual component renders property, but this.count is undefined. After some searching I found: https://blog.bitsrc.io/using-angular-elements-why-and-how-part-1-35f7fd4f0457 which seems like what I’m doing is correct but i’m obviously doing something wrong because I’m getting undefined. Anyone have any experience with this?

Michael Prentice
@Splaktar
Any tips for removing this error on ng serve with Ivy?
WARNING in /Users/splaktar/Git/devintent/src/environments/environment.prod.ts is part of the TypeScript compilation but it's unused.
Add only entry points to the 'files' or 'include' properties in your tsconfig.
Alan Agius
@alan-agius4

@Splaktar yeah, you need to include only the files that are needed in the compilation.

Using the below tsconfig should solve the issue.

{
  "extends": "./tsconfig.json",
  "compilerOptions": {
    "outDir": "./out-tsc/app",
    "types": []
  },
  "files": [
    "src/main.ts",
    "src/polyfills.ts"
  ],
  "include": [
    "src/**/*.d.ts"
  ]
}

PS: At the moment, I am working on a migration for this

@rvalimaki the issue is related to angular/angular-cli#15453
JuanCarlosJr97
@juancarlosjr97

Hello

How can I solve this issue

QuestionsComponent.html:233 ERROR Error: ExpressionChangedAfterItHasBeenCheckedError: Expression has changed after it was checked. Previous value: 'ngIf: false'. Current value: 'ngIf: true'.
Eric
@sliceofbytes
Ensure whatever value is in the ngIf is not being updated/changed between change detection cycles
Ron Fogel
@ronfogel
Hey Guys, after updating my angular cli (from 8.2.1 to 8.3.2) + core (from 8.2.2 to 8.2.4) my circle ci build fails, any idea why?
Generating ES5 bundles for differential loading...
An unhandled exception occurred: cancel after 1 retries!
See "/tmp/ng-8Tr7C1/angular-errors.log" for further details.
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! frontend-mallabee@2.0.1 build-dev: `ng build --configuration dev`
npm ERR! spawn ENOENT
npm ERR! 
npm ERR! Failed at the frontend-mallabee@2.0.1 build-dev script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/circleci/.npm/_logs/2019-08-31T09_20_07_881Z-debug.log
Exited with code 1
I cant reproduce it locally
JuanCarlosJr97
@juancarlosjr97
Did you change any environment variable???
@ronfogel
Ron Fogel
@ronfogel
Nothing special
Actually, the only environment variable exists when you do ng new is production: false/true (I dont have that in my environment file)
Adnan Ebrahimi
@adnanebrahimi
Does anyone knows how to use Service inside Libs?
I want to generate a service inside Libs and use it everywhere
Eric
@sliceofbytes
export your service and add it to the public_apis
Adnan Ebrahimi
@adnanebrahimi
what is public_apis ?
Note that i am using Nx.dev and i have a mono repo with 3 angular apps inside it. i want to create a http libs and use it in these 3 apps
Eric
@sliceofbytes
It's where you define your exports for a library
public_api.ts
JonathanFloresPacheco
@JonathanFloresPacheco
Hello
I need help with a MatTableDataSource. How can I get access to the data to modify a value that will bring me from a post?
aditya
@adibro500
hi i m having issue with implementing proxy using angular-cli
my proxy.conf.json looks like this
"/api": {
"target": "http://10.89.99.234:8111",
"secure": false,
"changeOrigin": true
}
}
my command to start the dev server is:
ng serve --proxy-config proxy.conf.json --host 0.0.0.0 --port 4500
can plz anyone help me with this ?
i am looking for a quick fix
the proxy details are altered for security reasons
can anyone plz give a look at my issue ?
aditya
@adibro500
thanks in advance ;-)
Sathish Jayapal
@sathishjayapal
Hello- am trying to package the angular CLI 8.x version and install. But it is looking to answer the google analytics prompt. Am trying to automate this and deploy this in a few hundred machines, is there a way that this question does not have to be answered during install.
Sathish Jayapal
@sathishjayapal
Hello- am trying to package the angular CLI 8.x version and install. But it is looking to answer the google analytics prompt. Am trying to automate this and deploy this in a few hundred machines, is there a way that this question does not have to be answered during install. More information about this "https://github.com/angular/angular/blob/master/aio/content/marketing/analytics.md", when doing a package install pushing to other machines it gets tricky and is expecting a user prompt. Any advise on how to get around this., thanks.
ZBAGI
@ZBAGI
Is there a way to create inline modal in angular2 material design ?
mikejf-pr
@mikejf-pr
Hi; with angular cli builders, is there a way to have muiltiple builders for 'serve' which happen sequentially? I'd like to keep using the build-angular builder task (and looking at in future switching to bazel) but have a postbuild operation which happens after builds, including after ng serve rebuilds
ZBAGI
@ZBAGI
@ZBAGI
Why @angular/cdk/keycodes doasnt contain DOUBLE_QUOTA or something like that " ??
it only contains code SINGLE_QUOTE
I have checked and numer assigned to it:
export declare const SINGLE_QUOTE = 222; and looks like 222 is a Quote code not SINGLE_QUOTE as in angular
David Stellini
@davidstellini
Hey guys, a bit of an annoying question with material design. I have managed to get dynamic themes to work - this is quite easy. But now it seems that the client wants to be able to pick the primary colour and accent colour using a palette
Now, aside from recompiling all the scss per client - is there any feasible option to change the primary and accent colours at runtime?
Again - these are not predetermined, otherwise it would be super easy.
Eric
@sliceofbytes
Set all the material2 colors to a css-variable