You need to sign in or sign up before continuing.
davidlbean
Joined
Activity
Posted in Trix editor in react native
Aha...and I needed to watch this for the last step: https://gorails.com/episodes/trix-editor?autoplay=1
Posted in Trix editor in react native
For anyone else working on this issue, I've made some progress:
I created a route in the Rails backend that requires no authentication and will render a trix-editor element along with some customizations I like. I have RN call that route when rending a WebView component. In the HTML template that renders the trix-editor, I also added a Save button and on the button's click event handler, I call this: window.ReactNativeWebView.postMessage(trix_editor.innerHTML). Back in RN, the WebView component accepts that message and stuffs the data into a state var that I can then drop into a set of attributes/values to submit to the backend to actually create the associated record.
The idea I'm working on is to have a generic rich text editor delivered via WebView such that I can drop it into any form and work as if the rich text field were just another input field.
Posted in Trix editor in react native
Anyone have suggestions for how to implement the trix editor in a react native front end? The key is I want to maintain trix’s mention functionality and the attachment of images. Ultimately I’d like to replicate how basecamp does this in their mobile app. Seems like using a webview is the easiest approach. If so, do you use a generic endpoint for editing a rich content field or do you serve up a page for the rich content editing of each of your models?
Awesome...thanks, Chris! And yah, I feel like I'm swimming upstream by running Sublime instead of VSCode, but old dogs and new tricks, eh?
Nice video, Collin!
One thing I might add is how to get into a debug console when you're running the default bin/dev script. I spin up another console and run "bundle exec rdbg -a" to attach to the debug process. Is there any easier way to get all the goodness of the debug gem in way that integrates into the bin/dev foreman setup?
Posted in Rails Components From Scratch Discussion
Super episode -- putting this to work right now.
Kieran - did you ever get this sorted out? I just banged my head against the wall for a few days trying to solve it myself. Finally got somewhere. I've put up a github repo with a sample Rails app and a pdf with my learnings. If you're interested, you can find it here: https://github.com/davidlbean/rails_with_vuetify
Chris - an awesome series, as usual! Question: (and I saw this on the active cable video too) when you checked for a logged in user, you dropped down to Warden. Why do this as opposed to just calling the Devise methods like signed_in?
Thx.
+1
Posted in Symbols vs Strings Discussion
Hey Rob - I could give you some pointers on that kind of thing. Are you in the slack channel where I could DM you? - David
Keep the stimulus stuff coming!
Posted in Symbols vs Strings Discussion
Nice! Some of my upper division CS students struggle with the notion of symbols, and I'll point them this way.
Awesome, as usual!
Fantastic screencast, Chris.