Skip to content

Commit

Permalink
refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
fnhipster committed Jan 26, 2024
1 parent effa3d2 commit 3ad4301
Show file tree
Hide file tree
Showing 107 changed files with 22 additions and 28 deletions.
10 changes: 5 additions & 5 deletions head.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@
<script type="importmap">
{
"imports": {
"@dropins/elsie/": "/scripts/__vendors__/dropins/elsie/",
"@dropins/storefront-cart/": "/scripts/__vendors__/dropins/storefront-cart/",
"@dropins/storefront-checkout/": "/scripts/__vendors__/dropins/storefront-checkout/",
"@dropins/storefront-pdp/": "/scripts/__vendors__/dropins/storefront-pdp/",
"@dropins/storefront-order-confirmation/": "/scripts/__vendors__/dropins/storefront-order-confirmation/"
"@dropins/elsie/": "/scripts/__dropins__/elsie/",
"@dropins/storefront-cart/": "/scripts/__dropins__/storefront-cart/",
"@dropins/storefront-checkout/": "/scripts/__dropins__/storefront-checkout/",
"@dropins/storefront-pdp/": "/scripts/__dropins__/storefront-pdp/",
"@dropins/storefront-order-confirmation/": "/scripts/__dropins__/storefront-order-confirmation/"
}
}
</script>
Expand Down
16 changes: 16 additions & 0 deletions install_dropins.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
#!/bin/bash


# Remove existing dropins folder
rm -rf scripts/__dropins__

# Create scripts/__dropins__ directory if not exists
mkdir -p scripts/__dropins__

# Copy specified files from node_modules/@dropins to scripts/__dropins__/dropins
cp -R node_modules/@dropins/* scripts/__dropins__/

# Remove package.json files inside dropins
find scripts/__dropins__ -type f -name "package.json" -exec rm {} \;

echo "🫡 Vendors installed successfully!"
22 changes: 0 additions & 22 deletions install_vendors.sh

This file was deleted.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
"lint:css": "stylelint blocks/**/*.css styles/*.css",
"lint": "npm run lint:js && npm run lint:css",
"start": "aem up --print-index",
"install:dropins": "bash ./install_vendors.sh",
"install:dropins": "bash ./install_dropins.sh",
"postinstall": "npm run install:dropins",
"postupdate": "npm run install:dropins"
},
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 3ad4301

Please sign in to comment.