Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

4.0.0-beta.18 Slides was not found in @ionic/angular #16737

Closed
dm-AS opened this issue Dec 14, 2018 · 2 comments
Closed

4.0.0-beta.18 Slides was not found in @ionic/angular #16737

dm-AS opened this issue Dec 14, 2018 · 2 comments
Labels

Comments

@dm-AS
Copy link

dm-AS commented Dec 14, 2018

Bug Report

Ionic version:
[x] 4.0.0-beta.18

Current behavior:
Building doesn't work beacause 'Slides' was not found in '@ionic/angular'.

Expected behavior:
In beta 17 everything worked fine.

Steps to reproduce:
I updated from beta 17 to 18 and the working 'Slides' failed.

Related code:

import {Component, OnInit, ViewChild} from '@angular/core';
import {ActivatedRoute} from '@angular/router';
import {Slides} from '@ionic/angular';

@Component(...)
export class NamesDetailPage implements OnInit {
    id: string;
    type: string;
    list: Array<any>;

    @ViewChild(Slides) slides: Slides;

    constructor(private route: ActivatedRoute) {
    }

    ngOnInit() {
        this.id = this.route.snapshot.paramMap.get('id');
        this.type = this.route.snapshot.paramMap.get('type');
        for (const container of this.asDataService.getNames()) {
            if (container.gender === this.type) {
                this.list = container.list;
                container.list.forEach((item, index) => {
                    if (item.id === this.id) {
                        this.slides.slideTo(index + 1);
                    }
                });
            }
        }
    }
}

Ionic info:

Ionic:

   ionic (Ionic CLI)             : 4.5.0 (/usr/local/lib/node_modules/ionic)
   Ionic Framework               : @ionic/angular 4.0.0-beta.18
   @angular-devkit/build-angular : 0.10.7
   @angular-devkit/schematics    : 7.0.7
   @angular/cli                  : 7.0.7
   @ionic/angular-toolkit        : 1.2.0

Capacitor:

   capacitor (Capacitor CLI) : 1.0.0-beta.11
   @capacitor/core           : 1.0.0-beta.11

Cordova:

   cordova (Cordova CLI) : 8.1.2 (cordova-lib@8.1.1)
   Cordova Platforms     : none
   Cordova Plugins       : cordova-plugin-ionic-keyboard 2.1.3, (and 12 other plugins)

System:

   ios-deploy : 1.9.4
   ios-sim    : 7.0.0
   NodeJS     : v11.4.0 (/usr/local/Cellar/node/11.4.0/bin/node)
   npm        : 6.5.0
   OS         : macOS Mojave
   Xcode      : Xcode 10.1 Build version 10B61
@ionitron-bot ionitron-bot bot added the triage label Dec 14, 2018
@paulstelzer
Copy link
Contributor

Thanks for your issue. Please take a look at the breaking changes for beta.18: https://github.com/ionic-team/ionic/blob/master/CHANGELOG.md#angular-prefixed-ion--components

Everything is prefixed with Ion, so instead of Slides it's IonSlides:

import {IonSlides} from '@ionic/angular';

...

@ViewChild(IonSlides) slides: IonSlides;

@ionitron-bot
Copy link

ionitron-bot bot commented Jan 13, 2019

Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out.

@ionitron-bot ionitron-bot bot locked and limited conversation to collaborators Jan 13, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants