Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Oct 15 15:20
    alanhg commented #1997
  • Sep 30 15:12
    bbrink68 commented #2049
  • Aug 23 13:34
    SouravKumar89 edited #2058
  • Aug 23 13:27
    SouravKumar89 opened #2058
  • Aug 22 00:04

    PatrickJS on master

    Update README.md (compare)

  • Aug 13 17:17
    ramsunvtech commented #1925
  • Aug 12 22:58
    terrancecorley commented #770
  • Aug 09 02:30
    jindovu commented #2049
  • Aug 09 02:22
    jindovu opened #2057
  • Aug 08 10:49
    krawinkelm commented #2053
  • Jul 21 14:14
    FilipLitwora commented #958
  • Jul 21 14:14
    FilipLitwora commented #958
  • Jul 21 14:14
    FilipLitwora commented #958
  • Jul 09 11:40
    Sanafan commented #1713
  • Jul 05 11:41
    hoang-innomizetech commented #2053
  • Jul 05 07:32
    Jilaba commented #1824
  • Jun 29 04:31
    Jason-Cooke synchronize #2055
  • Jun 28 14:51
    jesslilly commented #1827
  • Jun 12 18:16
    dvaldivia commented #1969
  • Jun 12 17:55
    dvaldivia commented #2049
Alexander B.
@alexanderbelko
I've done npm install --save primeng
But when I try to use any component, getting error: Error: Template parse errors: 'p-accordionTab' is not a known element: 1. If 'p-accordionTab' is an Angular component, then verify that it is part of this module.
NIkunj Baid
@Nik29
hey . I am unable to run ng generate component name . The error is : Unable to read property '0' of undefined. I am using @angular/cli@latest . OS: Windows 8.1 Angular 6.9.0 . npm :3.10.10 . Please help.
Forrest Murray
@FMurray
how to I get more descriptive stack traces? It seems like the dll is obscuring a lot
EXCEPTION: Uncaught (in promise): Error: Error in ./ProductComponent class ProductComponent - inline template:62:13 caused by: Cannot read property '0' of undefined
Error: Error in ./ProductComponent class ProductComponent - inline template:62:13 caused by: Cannot read property '0' of undefined
    at ViewWrappedError.ZoneAwareError (http://localhost:3000/polyfills.dll.js:4731:33)
    at ViewWrappedError.BaseError [as constructor] (http://localhost:3000/vendor.dll.js:28595:16)
    at ViewWrappedError.WrappedError [as constructor] (http://localhost:3000/vendor.dll.js:28660:16)
    at new ViewWrappedError (http://localhost:3000/vendor.dll.js:58640:16)
    at CompiledTemplate.proxyViewClass.DebugAppView._rethrowWithContext (http://localhost:3000/vendor.dll.js:80035:23)
    at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (http://localhost:3000/vendor.dll.js:80008:18)
    at CompiledTemplate.proxyViewClass.AppView.internalDetectChanges (http://localhost:3000/vendor.dll.js:79795:18)
    at CompiledTemplate.proxyViewClass.View_ProductComponent_Host0.detectChangesInternal (/AppModule/ProductComponent/host.ngfactory.js:29:19)
    at CompiledTemplate.proxyViewClass.AppView.detectChanges (http://localhost:3000/vendor.dll.js:79810:14)
    at CompiledTemplate.proxyViewClass.DebugAppView.detectChanges (http://localhost:3000/vendor.dll.js:80005:44)
    at ViewRef_.detectChanges (http://localhost:3000/vendor.dll.js:59572:20)
    at RouterOutlet.activate (http://localhost:3000/vendor.dll.js:65112:42)
    at ActivateRoutes.placeComponentIntoOutlet (http://localhost:3000/vendor.dll.js:23665:16)
    at ActivateRoutes.activateRoutes (http://localhost:3000/vendor.dll.js:23632:26)
    at http://localhost:3000/vendor.dll.js:23568:58
    at Array.forEach (native)
    at ActivateRoutes.activateChildRoutes (http://localhost:3000/vendor.dll.js:23568:29)
    at ActivateRoutes.activate (http://localhost:3000/vendor.dll.js:23542:14)
    at http://localhost:3000/vendor.dll.js:23110:22
    at SafeSubscriber._next (http://localhost:3000/vendor.dll.js:171:21)
    at SafeSubscriber.__tryOrSetError (http://localhost:3000/vendor.dll.js:600:16)
    at SafeSubscriber.next (http://localhost:3000/vendor.dll.js:542:27)
    at Subscriber._next (http://localhost:3000/vendor.dll.js:493:26)
    at Subscriber.next (http://localhost:3000/vendor.dll.js:457:18)
YUCK
hitoz
@hitoz
Hello there
hitoz
@hitoz

i am using angular in memory web api package on my project that build based on angular2 webpack starter,

i am using lazy loading for each submodules, i realized that every submodule will be loaded when the app is navigating somewhere..
the problem is, i import my angular in memory web api inside the submodule, to use the mockup API..
after i saved the data on mockup API, its working.. but when i navigate to somewhere else, the data will be reset (I think this is because we reload submodule again)..

For example:
I am going to update User, i am doing PUT 'api/users/5';
if i am not redirect to anywhere, the data will be keep..

but when i am going to navigate to list of user GET 'api/users';
the data will be reset because the module will be reload again..

FYI, update user form and list of user view is in a same module, why it load twice ? should be once right ?

roded
@roded
Hello, I'm wondering what's the best practice for the following scenario: I'd like to use the zxcvbn library in my ng2-webpack-starter app. (zxcvbn is a password-strengh js library distributed via npm, there's also the TypeScript def file for it on github somewhere). Thing is, as the library is several 00s kbytes in size and should be used from a minimal set of pages in the application, I'd like to load it dynamically and not bundle it with the whole app via webpack. Is there a recommended method of accomplishing this? Much obliged & thanks
donald-slagle
@donald-slagle
Does anyone know why my styles are not being applied? I can see the exports.push section in main.bundle.js that contains all the compiled styles from my sass files. This includes bootstrap, but basic classes like row do not have any bootstrap styles applied. I'm using the default loader configuration that comes with the started project.
donald-slagle
@donald-slagle
I have import 'assets/sass/app.scss'; added to main.browser.ts.
alisherabd
@alisherabd
after I run "npm run build:docker" and the image is ready locally, what shpuld I do next?
perrierism
@perrierism
having a lot of trouble getting some 3p libraries into an app here here ... for instance moment.js :
it provides it's own typings but any import / require I try doesn't get it defined in the app.
where it seems I can just do import {MomentModule} from 'angular2-moment'; ... which doesn't raise any errors, but, MomentModule is still not defined ...
anyone use moment, or have any pointers on how to import a module like this?
Forrest Murray
@FMurray
@alexanderbelko did you add primeeng to your app.module ?
@perrierism where is MomentModule not defined?
@donald-slagle are you trying to load global styles?
@alisherabd what are you trying to accomplish with your docker image?
webdev48
@webdev48
I am using this starter kit trying to read a simple json file from a service...it throws 404
can anyone help?
export class MyService {

  public data:any;

  constructor(private http:Http) {
    this.http.get('/data/settings.json')
      .subscribe(res => this.data = res.json());
  }
}
Forrest Murray
@FMurray
@webdev where are you using the service? did you add it to the providers?
webdev48
@webdev48
yes all of that is fine... obviously i am consuming it in a component

@Component({
  selector: 'home',  // <home></home>
  providers: [
    MyService
  ],
  styleUrls: [ './home.component.css' ],
  templateUrl: './home.component.html'
})
export class HomeComponent implements OnInit {

  // TypeScript public modifiers
  constructor(
    public myService: MyService
  ) {
    console.log(myService.data);

  }
}
Forrest Murray
@FMurray
Is that all the code? \
You need to use @Injectable decorator I believe
webdev48
@webdev48
im using that as well on the service
Forrest Murray
@FMurray
.subscribe(res => this.data = res.json().data)
webdev48
@webdev48
already doing that in the service if you look above ^^ and it does not need .data in the end
its a 404 dude EXCEPTION: Response with status: 404 Not Found for URL: http://localhost:4000/data/settings.json
Carlos Esteban Lopez Jaramillo
@luchillo17
Anyone can explain me what does this do in webpack config?
// Fix Angular 2
      new NormalModuleReplacementPlugin(
        /facade(\\|\/)async/,
        helpers.root('node_modules/@angular/core/src/facade/async.js')
      ),
      new NormalModuleReplacementPlugin(
        /facade(\\|\/)collection/,
        helpers.root('node_modules/@angular/core/src/facade/collection.js')
      ),
      new NormalModuleReplacementPlugin(
        /facade(\\|\/)errors/,
        helpers.root('node_modules/@angular/core/src/facade/errors.js')
      ),
      new NormalModuleReplacementPlugin(
        /facade(\\|\/)lang/,
        helpers.root('node_modules/@angular/core/src/facade/lang.js')
      ),
      new NormalModuleReplacementPlugin(
        /facade(\\|\/)math/,
        helpers.root('node_modules/@angular/core/src/facade/math.js')
      ),
Carlos Esteban Lopez Jaramillo
@luchillo17
Ok seems nobody will answer the last one, how about this one, i've tested the AoT with @ngtools/webpack and it looks simpler than the one used in this repo at this moment, is there any good reason to stick with ngc-webpack?
alisherabd
@alisherabd
@FMurray I just wanted to see docker container in use. Let's say I have this production image, how do I load it locally with docker and see on browser, before deploying to cloud?
Alen
@Devgaze
Hi everyone, so I'm trying to build my project and it finishes it without any errors, my first page loads but when I try to access users page directly by entering URL path it throws 404. Trying to do the same while dev server running just works fine. The only thing I changed in router module is location strategy to push strategy. I tried the same thing on the repo itself and it doesn't work as well, so I'm thinking did I forgot to change something else? Any help appreciated
Steps to reporoduce:
  1. git clone --depth 1 https://github.com/angularclass/angular2-webpack-starter.git
  2. npm install
  3. in src/app/app.module.ts remove following , { useHash: false, preloadingStrategy: PreloadAllModules }
  4. run npm run build:prod
  5. run npm run server:prod
  6. navigate to http://127.0.0.1:8080/details
Alen
@Devgaze
what am I missing here (I'm getting a feeling it's one of those situations when you don't see an elephant in front of you) :worried:
Alen
@Devgaze
ok I'm an dumbass, I didn't provide web.config (.htaccess) in CopyWebpackPlugin
Forrest Murray
@FMurray
@alisherabd what version of the docker host do you have?
Carlos Esteban Lopez Jaramillo
@luchillo17
Anyone can explain me what does this do in webpack config?
// Fix Angular 2
      new NormalModuleReplacementPlugin(
        /facade(\\|\/)async/,
        helpers.root('node_modules/@angular/core/src/facade/async.js')
      ),
      new NormalModuleReplacementPlugin(
        /facade(\\|\/)collection/,
        helpers.root('node_modules/@angular/core/src/facade/collection.js')
      ),
      new NormalModuleReplacementPlugin(
        /facade(\\|\/)errors/,
        helpers.root('node_modules/@angular/core/src/facade/errors.js')
      ),
      new NormalModuleReplacementPlugin(
        /facade(\\|\/)lang/,
        helpers.root('node_modules/@angular/core/src/facade/lang.js')
      ),
      new NormalModuleReplacementPlugin(
        /facade(\\|\/)math/,
        helpers.root('node_modules/@angular/core/src/facade/math.js')
      ),
Ok seems nobody will answer the last one, how about this one, i've tested the AoT with @ngtools/webpack and it looks simpler than the one used in this repo at this moment, is there any good reason to stick with ngc-webpack?
beyersito
@beyersito
Hi, I am trying to deploy to a subdomain
but I cant get it to work
Alexander B.
@alexanderbelko
@FMurray Unfortunatly, no. I've spent a lot of time looking for working recipe
alisherabd
@alisherabd
@FMurray it's Docker version 17.03.1-ce
Kaito Yuuki
@KaitoYuuki_twitter
someone can share with me a app example made with angular2-webpack-starter please :) ?
Roman Gorodeckij
@holms
@KaitoYuuki_twitter been asking same thing earlier, there's none probably. i mean this starter barelly works, it's a mess in here all over the place especially in webpack config. time to leave this channel
Brandon James
@nla-brandonjames
How do I use third party scss with this boilerplate code?