Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for dynamic sides and targets #355

Closed
wants to merge 34 commits into from

Conversation

peterp
Copy link
Contributor

@peterp peterp commented Mar 29, 2020

We support two sides: api and web in RedwoodJS. This pull-request adds the ability to specify many sides, to provide configuration for those sides, and to have our build/ dev/ test/ lint/ generator tooling support those sides.

The idea is to move us out of a space where we're only supporting an "api" and "web" side, by removing the references to "api" and "web" in the code and making them controlled via configuration.

🕊This code is backwards compatible and will not introduce any breaking changes.

  • Make dev-server accept a side param
  • Make CLI "sides aware"
  • Make core configurations "side aware"

The future idea is that we could add first class support for electron and react-native.

# redwood.toml

[app]
   path = './app/renderer'
   target = 'react-native' # 'react-native-expo'

[desktopMain]
  path = './desktop/main'
  target = 'electron-main'

[desktopRenderer]
  path = './desktop/renderer'
  target = 'electron-renderer'

[web]
   path = './web'
   target = 'browser'

[api]
   path = './api'
   target = 'node'  # 'node-netlify' | 'node-aws' | 'node-zeit' | 'node-express'

@peterp peterp changed the title Add support for dynamic side targets Add support for dynamic sides and targets Mar 29, 2020
@peterp
Copy link
Contributor Author

peterp commented May 21, 2020

A bunch of this code was merged into #573, the concept of sides is not going away - but will be added more incrementally.

@peterp peterp closed this May 21, 2020
@thedavidprice thedavidprice deleted the pp-add-support-for-dynamic-side-targets branch May 22, 2020 20:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant