@joeldrapper we use newrelic, which has yml configs
@joeldrapper we use newrelic, which has yml configs
@henrik Nice.
Yea, the thing i built by default doesnt hide the namespace.
It does however allow you to customize the behavior to do that if you so wish. I think there are some examples of that in the readme.
If you use Zed and work with ERB templates in a Rails app, and would like to use erb_lint & htmlbeautifier to format them:
https://owaiskhan.me/post/formatting-and-linting-erb-files-with-zed
This was a great read: https://dashbit.co/blog/latency-rendering-liveview
@joeldrapper Following the selective rendering stuff with great interest.
Excited to see how it works. Some obvious benefits I guess are less data sent to the client + we stop rendering things on the server once we've found the thing we've been looking for.
Curious if therre are other/less-obvious benefits too?
For anyone stumbling across this, I wrote a gem that you can just add to your app and start using: https://github.com/owaiswiz/vc_shortcut
I wrote a blog post recently about speeding up code reloading in Rails for a faster feedback loop while developing.
https://owaiskhan.me/post/improving-performance-in-development-on-a-big-rails-app
Might be a significant enough improvement if you've got a huge Rails app with lots of routes and making a request after doing a code change locally is very slow for you.
If you use VSCode and have a lot of View Components, configuring explorer.fileNesting might clean up your `app/components` in the explorer a lot:
"explorer.fileNesting.enabled": true,
"explorer.fileNesting.patterns": {
"*_component.rb": "_${capture}_component_*.html.erb, ${capture}_component.html.erb, ${capture}_component.js, ${capture}_component_controller.js, ${capture}_component.scss"
},
I've always felt rendering ViewComponent with Rails is a bit too verbose.
Especially if you have namespaces. E.g:
render(Admin::Navigation::Item.new(label: 'Example'))
I've used a helper to make it nicer on 2 projects so far:
vc.admin.navigation.item(label: 'Example')
Maybe make it into a gem?
(Might seem a bit over-engineered on a first glance. But it's something that might be called 100s-1000s of time on a page, so had to make sure it's fast enough.