Skip to content

armgit / spree

Public Imported from GitHub
0

Open Source Platform for DTC, B2B Commerce, Marketplaces & Omnichannel. REST APIs, TypeScript SDKs, and production-ready Next.js storefront. Self-host it. Own your data. No vendor lock-in. Zero platform fees.

add yarn build to sandbox.sh

aryt7d10cfa80078
diff --git a/bin/sandbox.sh b/bin/sandbox.sh
index bca7e71bc6..2f55fb8908 100755
--- a/bin/sandbox.sh
+++ b/bin/sandbox.sh
@@ -104,12 +104,28 @@ if Rails.env.development? && defined?(Bullet)
end
RUBY
+bundle update
bundle install --gemfile Gemfile
bin/rails javascript:install:esbuild
bin/rails turbo:install
yarn install
+cat <<RUBY > package.json
+{
+ "name": "app",
+ "private": "true",
+ "dependencies": {
+ "@hotwired/turbo-rails": "^7.1.3",
+ "@spree/dashboard": "^0.2.0",
+ "esbuild": "^0.14.47"
+ },
+ "scripts": {
+ "build": "esbuild app/javascript/*.* --bundle --sourcemap --outdir=app/assets/builds"
+ }
+}
+RUBY
+
bin/rails db:drop || true
bin/rails db:create
bin/rails g spree:install --auto-accept --user_class=Spree::User --sample=true
@@ -117,3 +133,4 @@ bin/rails g spree:backend:install
bin/rails g spree:emails:install
bin/rails g spree:auth:install
bin/rails g spree_gateway:install
+yarn build