@peterp I’ve had a quick look at the Sides PR you’re working on, and I’ve seen the notion of target
within the Sides configuration.
Do you have some kind of a spec, or at least a vision about what those “targets” would encompass?
I’m asking because I heard/read things like “a react-native Side” several times now, and I think we should actually talk about React Native as a target
for a mobile/app (I guess the name wouldn’t be imposed on the dev?) Side.
What do you think? I’m sorry if that’s too much nitpicking at that stage, but I believe using the right terms is helpful to understand the concepts but also to be clear about where we’re headed and help us get there.
It also relates to a remark I made around plugins and Vue.js during our last meetup.
I think it’s @mojombo who talked about a vue
Side. I’d argue that we should be talking about a vue
target for the web
Side.
Designing it this way could allow us to use powerful conventions such as target-dependent builds or target-dependent generators (and maybe, if that makes sense, target-dependent deployments?).
For instance in a plugin-enabled future, when using yarn rw g page home /
, we could automatically load the redwood-[target]-page-generator
module to have the correct files generated depending on the target (e.g. Vue components for the vue
target).
At the moment, targets seem hardcoded into the framework, but as Redwood grows it could be possible to follow Rails’ path and extract parts of the code to official redwood-[target]-build
/ -generator
/ … modules, so that loading the layers to generate, build and deploy a Redwood app would become purely dynamic.
Once we have that, supporting technology xxx
in Redwood would just need someone to step up and create the proper redwood-xxx-
modules.
It’s definitely not going to happen tomorrow (and I have a tendency to get excited about quite uncertain & long-term things like this, sorry ), but targets seem like a good first step to pave the way?