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

Wrong platforms for different devices on build browser #10635

Closed
mburger81 opened this issue Mar 3, 2017 · 8 comments
Closed

Wrong platforms for different devices on build browser #10635

mburger81 opened this issue Mar 3, 2017 · 8 comments

Comments

@mburger81
Copy link
Contributor

Ionic version: (check one with "x")
[ ] 1.x
[x] 2.x

I'm submitting a ... (check one with "x")
[x] bug report
[ ] feature request
[ ] support request => Please do not submit support requests here, use one of these channels: https://forum.ionicframework.com/ or http://ionicworldwide.herokuapp.com/

Current behavior:
We bundle our app with ionic build browser --prod and serve it with an jetty webserver. After that we open the app from different devices with the browser and think there could be a problem on recognize the right platform.

Browser from destkop: [cordova, core]
Browser from smartphone: [cordova,mobile,android]
Browser from tablet: [cordova, core]
Browser from smartphone emulator: [cordova,mobile,android]

Expected behavior:
I'm not sure which should be the right behavior
core: means from DESKTOP and not from BROWSER
So I think anything is right expect the platforms for tablet, they should be [cordova,mobile,android,tablet] which would be exactly the same platforms open the hybrid app from tablet.

Ionic info: (run ionic info from a terminal/cmd prompt and paste output below):

Cordova CLI: 6.5.0 
Ionic Framework Version: 2.1.0-201702281739
Ionic CLI Version: 2.2.1
Ionic App Lib Version: 2.2.0
Ionic App Scripts Version: 1.1.4
ios-deploy version: Not installed
ios-sim version: Not installed
OS: Linux 4.8
Node Version: v6.10.0
Xcode version: Not installed
@mhartington
Copy link
Member

The cordova-browser platform is not really meant to be a deploy target at the moment.
It's still very much a "testing target" for quickly working with plugins, and does not have the full functionality that needed. This would explain why the platform detection is quite off in certain situations.

@jgw96 jgw96 added the v2 label Mar 3, 2017
@mburger81
Copy link
Contributor Author

@mhartington okay, but please can you explain us which is the right way to deploy our webapp to a webserver, with and without progressive webapp support? Now tat you include the amazing split pane and also the new grid like bootstrap we wan't also deploy the app to a webserver like jetty?
I can not find documentation about it.

@mhartington
Copy link
Member

It's something we're working improving.

Right now the best way would be to run npm run build --prod and just deploy the www folder

@mburger81
Copy link
Contributor Author

Thx I'll have a look to it on Monday when I'm back to work.

Split pane and new grid are amazing and the first big step to more trasversal desktop support, great work, I can't wait for new feature :)

@mburger81
Copy link
Contributor Author

@mhartington I tested build my webapp for browser doing npm run build --prod but I run into an error.

[09:11:35]  uglifyjs started ... 
[09:11:35]  sass: src/pages/data-recording/data-recording.scss, line: 2 
            File to import not found or unreadable: ngx-datatable/release/index. Parent style sheet: 
            /home/michi/software/workspace/web-client-ionic/src/pages/data-recording/data-recording.scss 

       L1:  data-recording {
       L2:      @import "ngx-datatable/release/index";
       L3:      @import "ngx-datatable/release/themes/material";

[09:11:35]  sass failed 
[09:11:35]  ionic-app-script task: "build" 
[09:11:35]  Error: Error 

I to two imports in data-recording.scss files importing index.css and material.css from node_modules folder configuring the path in local sass.config.js file

  includePaths: [
    'node_modules/@swimlane'
  ],

This is working fine for ionic serve, ionic emulate android --prod, ionic run android --prod and ionic build browser --prod

@mburger81 mburger81 reopened this Mar 8, 2017
@jgw96
Copy link
Contributor

jgw96 commented Mar 27, 2017

Hello! Thanks for opening an issue with us! As this seems like more of a support question i will urge that you ask this question on our forum or on our slack channel. Thanks for using Ionic!

@jgw96 jgw96 closed this as completed Mar 27, 2017
@mburger81
Copy link
Contributor Author

Okay thx, but's not a question, that's still a bug.

@ionitron-bot
Copy link

ionitron-bot bot commented Sep 3, 2018

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 Sep 3, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants