Skip to content

Commit

Permalink
https://github.com/elmsln/issues/issues/1614
Browse files Browse the repository at this point in the history
  • Loading branch information
btopro committed Jul 20, 2023
1 parent b10e3d6 commit 735c2c7
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 29 deletions.
18 changes: 12 additions & 6 deletions system/backend/php/lib/HAXCMSSite.php
Original file line number Diff line number Diff line change
Expand Up @@ -320,23 +320,29 @@ public function getServiceWorkerStatus() {
* @return array keyed array of files we wish to pull from the boilerplate and keep in sync
*/
public function getManagedTemplateFiles() {
// not everything is templated but ensures self refreshing if we need to bulk tweak / enhance
return array(
'htaccess' => '.htaccess', // not templated (yet) but ensures self refreshing if we tweak it
'404' => '404.html',
'msbc' => 'browserconfig.xml',
'dat' => 'dat.json',
// HAX core / application / PWA requirements
'htaccess' => '.htaccess',
'build' => 'build.js',
'buildlegacy' => 'assets/build-legacy.js',
'buildpolyfills' => 'assets/build-polyfills.js',
'buildhaxcms' => 'build-haxcms.js',
'index' => 'index.html',
'manifest' => 'manifest.json',
'package' => 'package.json',
'polymer' => 'polymer.json',
'push' => 'push-manifest.json',
'robots' => 'robots.txt',
'sw' => 'service-worker.js',
'outdated' => 'assets/upgrade-browser.html',
'404' => '404.html',
'msbc' => 'browserconfig.xml',
// local development tooling
'webdevserverhaxcmsconfigcjs' => 'web-dev-server.haxcms.config.cjs',
'package' => 'package.json',
'polymer' => 'polymer.json',
// Beaker browser
'dat' => 'dat.json',
// SCORM 1.2
'imsmdrootv1p2p1' => 'imsmd_rootv1p2p1.xsd',
'imscprootv1p1p2' => 'imscp_rootv1p1p2.xsd',
'adlcprootv1p2' => 'adlcp_rootv1p2.xsd',
Expand Down
26 changes: 3 additions & 23 deletions system/boilerplate/site/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,33 +19,13 @@
"access": "public"
},
"resolutions": {
"object-assign": "4.1.1",
"commander": "2.19.0",
"readable-stream": "1.1.14",
"isarray": "1.0.0",
"source-map": "0.5.7",
"kind-of": "6.0.2",
"is-number": "4.0.0",
"once": "1.4.0",
"minimist": "1.2.0",
"ajv": "6.5.5",
"fast-deep-equal": "2.0.1",
"json-schema-traverse": "0.4.1",
"@polymer/app-layout": "3.0.2"
},
"devDependencies": {
"@prettier/plugin-php": "^0.11.0",
"prettier": "^1.16.4",
"gulp": "^4.0.2",
"gulp-terser": "^1.2.0",
"rollup-plugin-terser": "5.2.0"
"@web/dev-server": "0.3.0"
},
"scripts": {
"lint": "prettier --check 'system/**/*.php' '*.{html,js,php,yml}'",
"format": "prettier --write 'system/**/*.php' '*.{html,js,php,yml}'",
"terser": "gulp",
"start": "yarn run dev",
"dev": "polymer serve --open --entrypoint dist/dev.html --allow-origin --open-path=/",
"dev": "web-dev-server -c web-dev-server.haxcms.config.cjs",
"dev-theme": "cd custom && yarn start"
}
}
}
10 changes: 10 additions & 0 deletions system/boilerplate/site/web-dev-server.haxcms.config.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
const path = require("path");
module.exports = {
watch: true,
https: true,
nodeResolve: true,
open: true,
dedupe: true,
rootDir: "./",
appIndex: path.join(process.cwd(), "index.html"),
};

0 comments on commit 735c2c7

Please sign in to comment.