šŸ›  New framework7-cli feedback needed

I tried repeated the process I did the first time. It worked this time. I probably just didnā€™t use the command ā€œnpm startā€ after the CLI installation, for I thought it was supposed to be ā€œnpm run devā€.
Thanks! This is a great.
BTW, this install was PWA, with Vue.js, Split View, default theme through CLI UI.

Thanks, man. It was my bad not reading the CLI instructions carefully.

Whenever I re-run another newly installed app, the previous app that I last opened shows up on the browser. Already cleared browsing data (both Chrome or Edge), still no luck.

Have you checked ServiceWorkers and AppCache in DevTools -> Application?

2 Likes

a possible ā€œbugā€

framework create

the app.js is generated with:

var app = new Framework7({
  root: '#app', // App root element
  id: 'io.framework7.myapp', // App bundle ID{{/if}}
  name: 'test', // App name
  theme: 'auto', // Automatic theme detection

in the line ā€œidā€, in the end you have an (possible) extra {{/ if}}
maybe the {{/if}} it could break something in the future

options:
:heavy_check_mark: All good, you have latest framework7-cli version.
? What type of the app are you targeting? Cordova app (target native iOS and And
roid)
? App (project) name: test
? App package (Bundle ID): io.framework7.myapp
? Target Cordova platform: Android
? What type of framework do you prefer? Framework7 Core
? Choose starter template: Single View
? Should we setup project with bundler? Webpack (recommended)
? Do you want to specify custom theme color? No, use default color theme

1 Like

Yeah, sounds like service worker caching. If you chosen ā€œPWAā€ on app creation, you need to worry about service workers. Check ā€œApplicationā€ section in DevTools

1 Like

Thanks, it wonā€™t affect anything, but you are right, better to remove :slight_smile:

If I create a default Cordova.app using the command-line and try to build-cordova-prod, bundling fails on XCode 10:

Non-system Ruby in use. This may cause packaging to fail.
If you use RVM, please run rvm use system.
If you use chruby, please run chruby system.
error: archive not found at path ā€˜/Volumes/ST5/develop/f7_gh1/cordova/platforms/ios/Golfheroes.xcarchiveā€™
** EXPORT FAILED **

I tried adding a build-flag, but that didnā€™t help:

ā€œbuild-cordova-iosā€: ā€œcross-env TARGET=cordova cross-env NODE_ENV=production node ./build/build.js && cd cordova && cordova build ā€“ --buildFlag=ā€™-UseModernBuildSystem=0ā€™ā€,

any other idea?

Can we add a build.json file for this, like mentioned here:
cordova build.json

I figured it out:

ā€œbuild-cordova-prodā€: ā€œcross-env TARGET=cordova cross-env NODE_ENV=production node ./build/build.js && cd cordova && cordova build --buildFlag=ā€™-UseModernBuildSystem=0ā€™ā€,

works

1 Like

Did you try the suggested thing to switch ruby?

In one of my apps i successfully use the following command to build. But this creates app-store ready archive:

cordova build ios --release --device --buildFlag="-UseModernBuildSystem=0" --packageType="app-store"

And i have the build.json but i am not sure does it make any difference

Thanks for the quick replyā€¦ I just found out we donā€™t need a build.json, we can pass the build-flag directly

Hopefully they release update soon for supporting ā€œmodern build systemā€

What really would be nice, if we could do a development build with integrated Testflight. (Last time I tried that, it was a major pita. Do you have any hints how to integrate that flawlessly?

I still manually upload package every time via Application Loader to TestFlight. But need to check, I am sure they must have an API for that

Iā€™m still playing with building the default project:
for me, the hideSplashscreen method is never called, because at the time it is called, window.navigator.splashscreen is undefined. Calling it a bit later makes it work:

 setTimeout(function(){
    cordovaApp.handleSplashscreen();
  },400);

(post withdrawn by author, will be automatically deleted in 24 hours unless flagged)

Read top of this thread and create v4 app with framework7-cli

I see now, Iā€™m sorry and Thank you.

With Cordova selected during installation, would I be able to test the app with PhoneGap build eventually?

Hi,

Always getting an error on [email protected] install during framework7-cli install. try both Node v10 ans node V11 but without success.

ERR! sharp EACCES: permission denied

Iā€™m on MacOS with sudo exec.

Guillaume