Scaffold - change templates

Hi,

as this is my first post in a community, let me first express my congrats and gratitude for creating such awesome FW. It looks like something that I was looking for since moving my path toward NodeJs world! Before moving to NodeJs I was using Grails (Groovy -based rails-style Fw) and done few projects with it (so, that’s maybe a reason why RW brings some good feeling) so please consider that majority of my questions coming from ‘comparing’ two FW and some features…

Let’s get back to the point: is there any way to change scaffold template files? In other words, I would like to implement some other UI kit / theme instead of default one (or, maybe just to add something to existing one) and, would like to include it in scaffold template (instead of generating scaffold and then adding changes to each scaffolded file…).

For example (and comparison) I will try to explain Grails WoW:

  • Generators use default scaffold templates (‘hidden’ somewhere under the hood of Fw)
  • There was a command called install-templates that would copy default templates in specific folder within project (all of them)
  • Any future generator usage would use local template files to generate scaffolds (if folder is available)

Thanky in advance for any comments (and sorry for a bit confused first post :slight_smile: )

BR
Zoran

Howdy Zoran! Welcome to the community!!

Believe what you’re looking for, Redwood also calls generators: Docs - CLI Commands : RedwoodJS Docs

Its not limited to just scaffolding, you can edit Cells, Pages, Components, etc. On an individual level too.

Hope it helps!

And just a P.S., Redwood takes quite a bit of inspiration from Rails as well, quite a few core contributors worked with it for a while.

1 Like

Thx! Somehow, I missed those lines after whole day digging the doca and source :joy:

Yes, I’m aware of your Rails background, even if I didn’t read it from intro, it is abvious from the RW concepts :wink: And, off-course, Grails was also inspired by Rails.

Once again, thank you for your support!

1 Like