I get lint problems in vsCode from webhint regarding background-image: image-set.
I use .browserslistrc in my root folder that is respected by webpack and babel but not webhint. (maybe because I use 2 environments in browserslist)
.browserslistrc:
[development]
last 2 chrome version
[production]
> 0.2%
not dead
not op_mini all
last 15 chrome versions
// and more..
problems in vsCode:
'background-image: image-set(
url(../images/ok-check-mark/ok-check-mark.png) 1x,
url(../images/ok-check-mark/ok-check-mark#2x.png) 2x,
url(../images/ok-check-mark/ok-check-mark#3x.png) 3x
)' is not supported by Chrome, Chrome Android, Edge, Firefox, Opera, Safari,
Safari on iOS, Samsung Internet. Add 'background-image: -webkit-image-set'
to support Chrome 21+, Chrome Android 25+, Edge 79+, Opera 15+, Safari 6+,
Safari on iOS 6+, Samsung Internet 1.5+.webhintcompat-api/css
After configuring .hintrc as follows:
.hintrc:
{
"extends": ["development"],
"hints": {
"typescript-config/consistent-casing": "off",
"typescript-config/strict": "off"
},
"browserslist": ["last 2 chrome version"]
}
It seams that webhint takes into account the definition.
problems in vsCode:
'background-image: image-set(
url(../images/ok-check-mark/ok-check-mark.png) 1x,
url(../images/ok-check-mark/ok-check-mark#2x.png) 2x,
url(../images/ok-check-mark/ok-check-mark#3x.png) 3x
)' is not supported by Chrome. Add 'background-image: -webkit-image-set'
to support Chrome 21+.webhintcompat-api/css
.hintrc also in root folder.
Didn't install hint.
I use webhint vsCode extension v2.1.4
Does webhint respect .browserslistrc environment settings ?
Related
Only on iPhone iOS 15.3 on 'Mobile Safari UI/WKWebView 15.3' viewing an asp.net v4.8 webapp with jQuery UI - v1.10.4 - 2014-01-17
Any suggestions on origin, or how to mitigate?
We recently migrated an Cordova App to Capacitor.
I am currently working on a feature, which uses Canvas blob data to create File (WebAPI), which we sent to an API.
But I noticed that the File API in the Capacitor WebView is outdated and broken:
In the Screenshot I am debugging the App on an iPhone 8 with iOS 14.3 and you will notice the size of the File is always zero and the name property somehow holds the actual data. (e is an Blob).
The first example shows creating a File from a blob, but afterwards the file has size 0 and the name is the BlobArray.
const e = blob;
new File([e], 'asdf', {type: e.type})
The second example shows the basic MDN File example, which works fine in Chrome and Desktop Safari, but on mobile it also uses the string array as name
new File(["foo"], "foo.txt", {
type: "text/plain",
});
I also tried this in just the iOS Safari Browser and it worked fine.
Therefore I have to assume that our Capacitor App uses an outdated Safari version.
Unfortunately I wasn’t able to find any information on how to set the WebView/Safari version for Ionic/Capacitor.
Here is my setup:
Device: iPhone 8
iOS version: 14.3
User-Agent of the ionic App:
Mozilla/5.0 (iPhone; CPU iPhone OS 14_3 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Mobile/15E148
User-Agent of iOS Safari:
Mozilla/5.0 (iPhone; CPU iPhone OS 14_3 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/14.0.2 Mobile/15E148 Safari/604.1
Packages and versions:
"#capacitor/cli": "2.4.6",
"#capacitor/core": "2.4.6",
"#capacitor/ios": "^2.4.6",
"ionic": "^5.4.14",
"#ionic/angular": "^5.4.1",
"#ionic/angular-toolkit": "~2.0.0",
"ionic-native": "^2.9.0",
"#ionic-native/file-transfer": "^5.29.0",
"cordova-plugin-file": "^6.0.2",
Is there a way to set the Safari Version for the WebView or might this be some case of misconfiguration on our part (because of the migration to capacitor)?
The only thing i can think of that would help, is try changing or updating to a different version of #capacitor/ios. This package is part of what controls the webview that capacitor uses. I don't think there is a way to directly set it.
I made a dummy project that uses "#capacitor/ios": "^2.4.5" and ran the second example you posted. Worked fine for me.
By looking at the File prototype in the debugger I noticed that the File constructor was completely different.
I googled the the code snippet and found out that the code is from the cordova-plugin-file package.
The plugin overwrites the global File variable.
Therefore the File Web API was not usable anymore.
By removing the plugin (and the plugin that depended on it) we were able to fix the issue.
Relevant Github Issue: https://github.com/apache/cordova-plugin-file/issues/453
I'm using the Intel XDK to build my Cordova app. I have an HTML/Javascript app that plays embedded Vimeo videos fine in web browsers.
When I build with Cordova CLI 5.1.1 things work fine as well for the iOS and Android apps.
When I build using Cordova CLI 5.4.1 or Cordova CLI 6.2.0 the Android app continues to play back Vimeo videos without issue, however for the iOS build the playback does not happen. The video area is still taking up the same amount of space, but displays a plain transparent/empty area with nothing visible in front of the background.
I started a topic here on the Vimeo forums without response.
https://vimeo.com/forums/help/topic:283713
In another thread, they responded briefly saying Vimeo does not support inline playback on mobile.
Any ideas on what might be a fix for this?
Okay, this issue was caused by the Whitelist changes to either the Intel XDK, or new versions of Cordova.
In the Intel XDK, under Projects -> Build Settings -> Whitelist > Navigation () I added *.vimeo.com
This caused the XDK file to update, in the following way:
"project": {
"buildConfigurations": {
"iOS": {
"appAccess_": {
"mode": "whitelist",
"network": [
"*"
],
"intents": [],
"navigation": [
"*.vimeo.com"
]
}
}
}
}
After this change, embedded Vimeo videos played fine in iOS app builds using Cordova 6.2.0
Note, the Network Request () entry under Whitelist was set to '*', not sure if that was relevant.
I have an Ionic application that worked well under iOS 8.
Now I have updated some code and included the network information plugin and updated to cordova-ios-3.9.2.
I have done some debugging for two days, but I get no errors, not in Xcode and not when I inspect the app using safari webinspector.
However, the app does not work anymore under iOS 8.1. It does work under iOS 9 and all Android versions.
I know it is a vague issue, I hope to find someone who can help. Maybe someone who knows the difference between iOS 8 and 9?
we are using the following plugins:
android.support.v4
com.internrocket.plugins.statusbarcolor
com.ionic.keyboard
cordova-plugin-console
cordova-plugin-crosswalk-webview
cordova-plugin-datepicker
cordova-plugin-device
cordova-plugin-network-information (this one is new between te previous and this release, but I think it does not break it)
cordova-plugin-splashscreen
cordova-plugin-statusbar
cordova-plugin-velda-devicefeedback
cordova-plugin-whitelist
cordova-plugin-x-toast
cordova-plugin-inappbrowser
The changes in the code are minor and well tested on all major browser, plus I get no error in the safari web-inspector, plus it works under iOS 9 so I do not suspect them.
Also strange is that the layout looks strange under IOS8. Maybe it is a css error? I have no idea if this is even possible?
Any help is appreciated!
EDIT:
What I have tried: use the previous ionic code with ios-cordova 3.9.2. This works. Also on iOS 8.1
So I had a similar issue, and I use this plugin:
https://github.com/sindresorhus/gulp-autoprefixer
The issue was that this plugin recommends the following implementation:
const gulp = require('gulp');
const autoprefixer = require('gulp-autoprefixer');
gulp.task('default', () =>
gulp.src('src/app.css')
.pipe(autoprefixer({
browsers: ['last 2 versions'],
cascade: false
}))
.pipe(gulp.dest('dist'))
);
What happened is that two weeks ago, iOS 9.3 was released, thus removing support for iOS 8 and breaking my app, and having some really irate customers.
The fix was to specify the versions I needed supported.
gulp.task('default', () =>
gulp.src('src/app.css')
.pipe(autoprefixer({
browsers: ['ios_saf >= 7', 'Chrome >= 42'],
cascade: false
}))
.pipe(gulp.dest('dist'))
);
Hope that helps someone out there!
The issues was with the CSS prefixes. Between releases we had accidentially removed some of them. Without the -webkit- css prefix the ios app breaks without warning or error.
I've setup MDS, installed the sim
Ran 2 simulators using sim1 and sim2.bat.
Added sim2 and a contact to sim1's BBM,
In Eclipse went to debug, dug configurations, Blackberry simulator, advanced.
Added this as my Customized command line:
"C:\Users\Adminy\AppData\Local\Research In Motion\
BlackBerry Smartphone Simulators 7.0.0\7.0.0.236 (9900)\
fledge.exe" /app=Jvm.dll /handheld=9900 /session=Sim1
/app-param=JvmAlxConfigFile:9900.xml /data-port=0x4d44
/data-port=0x4d4e /pin=0x2100000A /app-param=regVersion=3
/app-param=regDestIP=127.0.0.1 /app-param=regDestPort=19781
/app-param=regSrcPort=19783 /app-param=DisableSyncServiceRecord
This as my customized working dir:
C:\Users\Casey\AppData\Local\Research In Motion\
BlackBerry Smartphone Simulators 7.0.0\7.0.0.236 (9900)
And this as my customized MDS directory:
C:\bbmsdk\MDS Simulator\mds
But when I try to debug the sample apps they're not showing up on the simulator. Any ideas?