Coder Social home page Coder Social logo

angular-contrib's People

Contributors

angular-cli avatar dependabot-preview[bot] avatar dependabot[bot] avatar rafaelss95 avatar trotyl avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

angular-contrib's Issues

Infinite call stack for ngNoHost in prod mode

ngNoHost

https://github.com/pauldraper/angular-nohost-stack-error

ng serve

http://localhost:4200/ works.

http://localhost:4200/?prod has the error:

core.js:9110 ERROR RangeError: Maximum call stack size exceeded
    at InterceptingRenderer.renderer.childNodes (angular-contrib-core.js:1574)
    at InterceptingRenderer.renderer.childNodes (angular-contrib-core.js:1574)
    at InterceptingRenderer.renderer.childNodes (angular-contrib-core.js:1574)
    at InterceptingRenderer.renderer.childNodes (angular-contrib-core.js:1574)
    at InterceptingRenderer.renderer.childNodes (angular-contrib-core.js:1574)
    at InterceptingRenderer.renderer.childNodes (angular-contrib-core.js:1574)
    at InterceptingRenderer.renderer.childNodes (angular-contrib-core.js:1574)
    at InterceptingRenderer.renderer.childNodes (angular-contrib-core.js:1574)
    at InterceptingRenderer.renderer.childNodes (angular-contrib-core.js:1574)
    at InterceptingRenderer.renderer.childNodes (angular-contrib-core.js:1574)

Relevant code:

@Component({
  selector: 'stuff',
  host: { ngNoHost: '' },
  template: `
    Example
  `,
})
export class StuffComponent {}

@Component({
  selector: 'util',
  template: `
    <ng-container *ngTemplateOutlet="content"></ng-container>
  `,
})
export class UtilComponent {
  @ContentChild(TemplateRef, { static: false })
  content: TemplateRef<{}>;
}

@Component({
  selector: 'app',
  template: `
    <util>
      <ng-template>
        <stuff></stuff>
      </ng-template>
    </util>
  `,
})
export class AppComponent {
  @ContentChild(TemplateRef, { static: false })
  content: TemplateRef<{}>;
}

Conflict with angular-contrib/core and angular/platform-browser

I just tried to implement angular-contrib for its ngNoHost functionality and it is causing a conflict which is preventing my Angular 8 project from running.

I'm receiving this error:

ERROR in node_modules/@angular/platform-browser/animations/animations.d.ts(65,22): error TS2720: Class 'ɵangular_packages_platform_browser_animations_animations_f' incorrectly implements class 'Renderer2'. Did you mean to extend 'Renderer2' and inherit its members as a subclass?
Property 'childNodes' is missing in type 'ɵangular_packages_platform_browser_animations_animations_f' but required in type 'Renderer2'.
node_modules/@angular/platform-browser/animations/animations.d.ts(96,22): error TS2720: Class 'ɵAnimationRenderer' incorrectly implements class 'Renderer2'. Did you mean to extend 'Renderer2' and inherit its members as a subclass?
Property 'childNodes' is missing in type 'ɵAnimationRenderer' but required in type 'Renderer2'.

I've traced this back to here. I've tried recreating the bare bones example in my environment, and it still generates the same error. Is there a known incompatibility, am I missing something?

Project dead(?)

The last meaningful commit was made Oct 2019, and there are multiple significant confirmed issues (#233 #234) and an PR without comment (#175).

Please reply/close if this project is still maintained.

Conflict of Renderer2 typing extension with Angular 9

There is a small conflict with the Renderer2 extension with Angular 9 animations.

    ERROR in node_modules/@angular/platform-browser/animations/animations.d.ts:71:22 - error TS2720: Class 'ɵangular_packages_platform_browser_animations_animations_f' incorrectly implements class 'Renderer2'. Did you mean to extend 'Renderer2' and inherit its members as a subclass?
      Property 'childNodes' is missing in type 'ɵangular_packages_platform_browser_animations_animations_f' but required in type 'Renderer2'.
    
    71 export declare class ɵangular_packages_platform_browser_animations_animations_f implements Renderer2 {
                            ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    
      node_modules/@angular-contrib/core/render-extension/render-extension.module.d.ts:5:9
        5         childNodes(node: Node): NodeList;
                  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        'childNodes' is declared here.
    node_modules/@angular/platform-browser/animations/animations.d.ts:102:22 - error TS2720: Class 'ɵAnimationRenderer' incorrectly implements class 'Renderer2'. Did you mean to extend 'Renderer2' and inherit its members as a subclass?
      Property 'childNodes' is missing in type 'ɵAnimationRenderer' but required in type 'Renderer2'.
    
    102 export declare class ɵAnimationRenderer extends ɵangular_packages_platform_browser_animations_animations_f implements Renderer2 {
                             ~~~~~~~~~~~~~~~~~~
    
      node_modules/@angular-contrib/core/render-extension/render-extension.module.d.ts:5:9
        5         childNodes(node: Node): NodeList;
                  ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
        'childNodes' is declared here.

should ng-host be deprecated?

is there anything ng-host can do, that we cant do natively?

we have :host { ... } for styles and host: { ... } in the decorator to setup props/events + bindings

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.