Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 5 additions & 6 deletions Procfile.dev
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,13 @@
rails: REACT_ON_RAILS_ENV=HOT rails s

# Run the hot reload server for client development
rails-assets: sh -c 'rm app/assets/webpack/* || true && HOT_RAILS_PORT=3500 npm run build:dev:client'
hot-assets: sh -c 'rm app/assets/webpack/* || true && HOT_RAILS_PORT=3500 npm run hot-assets'

# Keep the JS fresh for server rendering. Remove if not server rendering
rails-server-assets: sh -c 'npm run build:dev:server'
# Render static client assets
rails-static-client-assets: sh -c 'npm run build:dev:client'

# If you don't keep this process going, you will rebuild the assets per spec run. This is configured
# in rails_helper.rb.
rails-test: sh -c 'npm run build:test:client'
# Render static client assets. Remove if not server rendering
rails-static-server-assets: sh -c 'npm run build:dev:server'

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we need this

please don't remove

this is used b/c above we do hot ones

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is still sort of necessary

# Run an express server if you want to mock out your endpoints. No Rails involved!
# Disable this if you are not using it.
Expand Down
7 changes: 6 additions & 1 deletion Procfile.spec
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
# For keeping webpack bundles up-to-date during a testing workflow.
# If you don't keep this process going, you will rebuild the assets per spec run. This is configured
# in rails_helper.rb.
rails-test: sh -c 'npm run build:test:client'

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we need this

# Build client assets, watching for changes.
rails-client-assets: sh -c 'npm run build:dev:client'

# Build server assets, watching for changes. Remove if not server rendering.
rails-server-assets: sh -c 'npm run build:dev:server'
2 changes: 1 addition & 1 deletion Procfile.static
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Run Rails without hot reloading (static assets)
# Run Rails without hot reloading (static assets).
rails: rails s
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not tru


# Build client assets, watching for changes.
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@
"build:clean": "rm app/assets/webpack/*",
"build:production:client": "(cd client && npm run build:production:client --silent)",
"build:production:server": "(cd client && npm run build:production:server --silent)",
"build:dev:client": "(cd client && npm run build:dev:client --silent)",
"build:client": "(cd client && npm run build:client --silent",
"build:dev:server": "(cd client && npm run build:dev:server --silent)",
"build:server": "(cd client && npm run build:server --silent)",
"build:dev:client": "(cd client && npm run build:dev:client --silent)",
"build:dev:server": "(cd client && npm run build:dev:server --silent)",
"hot-assets": "(cd client && npm run hot-assets)",
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

did you only change the order of the lines?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@justin808 correct

"start": "(cd client && npm run start --silent)"
},
Expand Down