build SW, fix order
This commit is contained in:
parent
d0d248a482
commit
35f313b2fc
@ -244,12 +244,13 @@ var updateAssetVersion = function (done) {
|
||||
.pipe(dest(paths.output));
|
||||
};
|
||||
// updates version in SW
|
||||
var updateSWVersion = function (done) {
|
||||
var buildSW = function (done) {
|
||||
return src('src/sw.js')
|
||||
.pipe(hashsrc({build_dir:paths.output,src_path:"src",hash_len:"6",query_name:"v",exts:[".json",".webp",".jpg",".css",".png",".ico",".js"],
|
||||
regex:/\s*(?:(")([^"]*)|(')([^']*))/ig,
|
||||
analyze: function analyze(match){return {prefix: "'",link:match[4],suffix: ''};}
|
||||
}))
|
||||
.pipe(jsTasks())
|
||||
.pipe(dest(paths.output));
|
||||
};
|
||||
// Watch for changes to the src directory
|
||||
@ -298,9 +299,9 @@ exports.default = series(
|
||||
buildSVGs
|
||||
),
|
||||
buildStyles,
|
||||
updateAssetVersion,
|
||||
buildScripts,
|
||||
updateSWVersion,
|
||||
updateAssetVersion,
|
||||
buildSW,
|
||||
);
|
||||
|
||||
// Watch and reload
|
||||
|
@ -2,9 +2,9 @@
|
||||
<browserconfig>
|
||||
<msapplication>
|
||||
<tile>
|
||||
<square70x70logo src="assets/img/favicon/mstile-70x70.png"/>
|
||||
<square150x150logo src="assets/img/favicon/mstile-150x150.png"/>
|
||||
<square310x310logo src="assets/img/favicon/mstile-310x310.png"/>
|
||||
<square70x70logo src="/img/favicon/mstile-70x70.png"/>
|
||||
<square150x150logo src="/img/favicon/mstile-150x150.png"/>
|
||||
<square310x310logo src="/img/favicon/mstile-310x310.png"/>
|
||||
<TileColor>#2b5797</TileColor>
|
||||
</tile>
|
||||
</msapplication>
|
||||
|
@ -45,8 +45,8 @@ echo '
|
||||
<meta name="apple-mobile-web-app-title" content="Meritvärde">
|
||||
<meta name="application-name" content="Meritvärde">
|
||||
<meta name="msapplication-TileColor" content="#2b5797">
|
||||
<meta name="msapplication-TileImage" content="img/favicon/mstile-144x144.png">
|
||||
<meta name="msapplication-config" content="img/favicon/browserconfig.xml">
|
||||
<meta name="msapplication-TileImage" content="/img/favicon/mstile-144x144.png">
|
||||
<meta name="msapplication-config" content="/img/favicon/browserconfig.xml">
|
||||
<meta name="theme-color" content="#27233a">
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user