Coder Social home page Coder Social logo

Comments (12)

squallliu avatar squallliu commented on May 26, 2024 1

try replacing ng-dynamic with ngTemplateOutlet
<template [ngTemplateOutlet]="alphaScrollTemplate" [ngOutletContext]="ionAlphaScrollRef"></template>

from ionic2-alpha-scroll.

rossmartin avatar rossmartin commented on May 26, 2024 1

@squallliu Thanks I wasn't aware of ngTemplateOutlet I'll try it out.

from ionic2-alpha-scroll.

rossmartin avatar rossmartin commented on May 26, 2024 1

@squallliu Not looking to be an easy replacement unfortunately and ngTemplateOutlet is labeled as experimental. I'll look into it some more soon.

from ionic2-alpha-scroll.

julianlecalvez avatar julianlecalvez commented on May 26, 2024

ok I think I fixed the problem by upgrading typescript to 2.1.5

EDIT : actually it didn't fix the pb, but I still get an error on lodash (I didn't get it last week it's weird) :

[15:55:17]  typescript: node_modules/@types/lodash/index.d.ts, line: 245 
            Cannot find name 'Partial'. 
     L245:      compact<TResult>(): LoDashImplicitArrayWrapper<TResult>;
[15:55:17]  transpile failed 
[15:55:17]  ionic-app-script task: "build" 
[15:55:17]  Error: Error 

from ionic2-alpha-scroll.

rossmartin avatar rossmartin commented on May 26, 2024

@julianlecalvez Yeah it appears that some of the latest versions of the @types/lodash definitions are broken. I locked in the dependency versions for lodash in the latest version (1.1.1). The error on lodash is gone now.

Thanks for looking into it.

from ionic2-alpha-scroll.

julianlecalvez avatar julianlecalvez commented on May 26, 2024

@rossmartin perfect ! it works !!
thanks a lot !

from ionic2-alpha-scroll.

julianlecalvez avatar julianlecalvez commented on May 26, 2024

Argh, maybe I have a bad news :(

it seems that the compilation passes but the execution not (on Android with the apk release).
I get this error when I try to access the view that contains the alpha-scroll :

main.js:23 EXCEPTION: No provider for t!
    t.handleError @ main.js:23
    e.onError.subscribe.next @ main.js:16
    e.object.r @ main.js:23
    e.__tryOrUnsub @ main.js:43
    e.next @ main.js:43
    e._next @ main.js:43
    e.next @ main.js:43
    e.next @ main.js:14
    e.emit @ main.js:23
    t.triggerError @ main.js:3
    inner.inner.fork.onHandleError @ main.js:3
    t.handleError @ polyfills.js:3
    e.runTask @ polyfills.js:3
    invoke @ polyfills.js:3

main.js:23 Error: No provider for t!
    at e.Error (native)
    at e [as constructor] (file:///android_asset/www/build/main.js:7:27316)
    at e [as constructor] (file:///android_asset/www/build/main.js:31:7138)
    at new e (file:///android_asset/www/build/main.js:31:7465)
    at t._throwOrNull (file:///android_asset/www/build/main.js:47:7966)
    at t._getByKeyDefault (file:///android_asset/www/build/main.js:47:8322)
    at t._getByKey (file:///android_asset/www/build/main.js:47:7876)
    at t.get (file:///android_asset/www/build/main.js:47:4238)
    at e.Object.defineProperty.get [as _Compiler_29] (file:///android_asset/www/build/main.js:43:16611)
    at e.getInternal (file:///android_asset/www/build/main.js:43:28884)t.handleError @ main.js:23e.onError.subscribe.next @ main.js:16e.object.r @ main.js:23e.__tryOrUnsub @ main.js:43e.next @ main.js:43e._next @ main.js:43e.next @ main.js:43e.next @ main.js:14e.emit @ main.js:23t.triggerError @ main.js:3inner.inner.fork.onHandleError @ main.js:3t.handleError @ polyfills.js:3e.runTask @ polyfills.js:3invoke @ polyfills.js:3

main.js:43 Uncaught Error: No provider for t!

:(

from ionic2-alpha-scroll.

rossmartin avatar rossmartin commented on May 26, 2024

That will occur if you build with the --prod flag. The issue with AoT compiling is related to what is described here - https://github.com/laco0416/ng-dynamic#dynamiccomponent-constraints

The problem is that there is no main.prod.ts anymore and if you try and use platformBrowser in the new main.ts it bombs out. When there was a main.prod.ts you could do this below in it and AoT would work -

import { platformBrowser } from '@angular/platform-browser';
import { enableProdMode } from '@angular/core';
import { COMPILER_PROVIDERS } from '@angular/compiler'; // import this

import { AppModuleNgFactory } from './app.module.ngfactory';

enableProdMode();
platformBrowser([
  COMPILER_PROVIDERS // dynamic content project used by ionic2-alpha-scroll needs this
]).bootstrapModuleFactory(AppModuleNgFactory);

from ionic2-alpha-scroll.

MoemenMostafa avatar MoemenMostafa commented on May 26, 2024

Any updates regarding this issue?

from ionic2-alpha-scroll.

rossmartin avatar rossmartin commented on May 26, 2024

@MoemenMostafa Sorry I haven't had time to look into it.

from ionic2-alpha-scroll.

anishtr4 avatar anishtr4 commented on May 26, 2024

Any updates on this ?

from ionic2-alpha-scroll.

rossmartin avatar rossmartin commented on May 26, 2024

resolved via #17

New major version 2.0.0 is available with this PR.

from ionic2-alpha-scroll.

Related Issues (20)

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.