From afc786236d20ac9284bc4411ee28ec23da5c8b58 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Th=C3=A9o=20Poizat?= Date: Mon, 3 Jun 2024 10:05:08 +0200 Subject: [PATCH 1/2] feat: Remove unused mobile target from create-cozy-app template --- .../cozy-scripts/template/app/src/targets/browser/index.ejs | 5 +---- .../cozy-scripts/template/app/src/targets/mobile/DOCS.md | 2 -- .../cozy-scripts/template/app/src/targets/mobile/config.xml | 0 .../cozy-scripts/test/__snapshots__/scripts.spec.js.snap | 2 -- 4 files changed, 1 insertion(+), 8 deletions(-) delete mode 100644 packages/cozy-scripts/template/app/src/targets/mobile/DOCS.md delete mode 100644 packages/cozy-scripts/template/app/src/targets/mobile/config.xml diff --git a/packages/cozy-scripts/template/app/src/targets/browser/index.ejs b/packages/cozy-scripts/template/app/src/targets/browser/index.ejs index a928d644a..1f22b984d 100644 --- a/packages/cozy-scripts/template/app/src/targets/browser/index.ejs +++ b/packages/cozy-scripts/template/app/src/targets/browser/index.ejs @@ -13,10 +13,7 @@ <% _.forEach(htmlWebpackPlugin.files.css, function(file) { %> <% }); %> - <% if (__TARGET__ === 'mobile') { %> - - - <% } else if (__STACK_ASSETS__) { %> + <% if (__STACK_ASSETS__) { %> {{.CozyBar}} <% } %> {{.ThemeCSS}} diff --git a/packages/cozy-scripts/template/app/src/targets/mobile/DOCS.md b/packages/cozy-scripts/template/app/src/targets/mobile/DOCS.md deleted file mode 100644 index 9ac66d690..000000000 --- a/packages/cozy-scripts/template/app/src/targets/mobile/DOCS.md +++ /dev/null @@ -1,2 +0,0 @@ -# Mobile development documentation -[Cozy Docs](https://cozy.github.io/cozy-docs-v3/en/dev/cordova/) diff --git a/packages/cozy-scripts/template/app/src/targets/mobile/config.xml b/packages/cozy-scripts/template/app/src/targets/mobile/config.xml deleted file mode 100644 index e69de29bb..000000000 diff --git a/packages/cozy-scripts/test/__snapshots__/scripts.spec.js.snap b/packages/cozy-scripts/test/__snapshots__/scripts.spec.js.snap index 6a463a20f..9cf06379e 100644 --- a/packages/cozy-scripts/test/__snapshots__/scripts.spec.js.snap +++ b/packages/cozy-scripts/test/__snapshots__/scripts.spec.js.snap @@ -109,8 +109,6 @@ Array [ "src/targets/browser/index.jsx", "src/targets/browser/setupApp.jsx", "src/targets/intents/.gitkeep", - "src/targets/mobile/DOCS.md", - "src/targets/mobile/config.xml", "src/targets/vendor/assets/icon.svg", "src/targets/vendor/assets/manifest.json", "src/utils/bar.js", From 214e5dbcbab17738ee1204996186692653a7c370 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Th=C3=A9o=20Poizat?= Date: Mon, 3 Jun 2024 10:05:51 +0200 Subject: [PATCH 2/2] refactor: Homogenize indentation in index.ejs --- .../cozy-scripts/template/app/src/targets/browser/index.ejs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/cozy-scripts/template/app/src/targets/browser/index.ejs b/packages/cozy-scripts/template/app/src/targets/browser/index.ejs index 1f22b984d..bbce22a67 100644 --- a/packages/cozy-scripts/template/app/src/targets/browser/index.ejs +++ b/packages/cozy-scripts/template/app/src/targets/browser/index.ejs @@ -11,10 +11,10 @@ <% _.forEach(htmlWebpackPlugin.files.css, function(file) { %> - + <% }); %> <% if (__STACK_ASSETS__) { %> - {{.CozyBar}} + {{.CozyBar}} <% } %> {{.ThemeCSS}} @@ -23,5 +23,5 @@ data-cozy="{{.CozyData}}" > <% _.forEach(htmlWebpackPlugin.files.js, function(file) { %> - + <% }); %>