Ken

Joined

3,480 Experience
34 Lessons Completed
0 Questions Solved

Activity

Are you using jQuery? I ask because I was having this same issue when wrapping the stripe js in

document.addEventListener("turbolinks:load", function () { ...

changing to

$(document).on("turbolinks:load", function() { ...

made it work. I don't understand why this should be different, and YMMV, but it for what it's worth that worked for me and stripe and turbolinks lived happily ever after.

Posted in Stripe Elements Javascript Discussion

Hi Foliwe,

I'm sure you've already figured this out, but for anyone coming across this same issue the problem is accessing the params incorrectly.

The user params are coming in as a hash:

"user"=>{"card_brand"=>"Visa", "card_exp_month"=>"4", "card_exp_year"=>"2024", "card_last4"=>"4242"}}

but are being accessed without providing the "user" key:

card_last4: params[:card_last4]

if you replace the code that looks like that above with:

card_last4: params[:user][:card_last4]

it should work fine.

Hi all, I'm trying to set up a Rails 5.2 app to directly upload images to Digital Ocean Spaces, and to then serve those images using Cloudfront. I'm able to do direct uploads to Spaces using ActiveStorage following #237, and I've configured Cloudfront as my asset host and everything in app/assets is served from there. But I can't figure out how to get the CDN to serve my images stored on Spaces. I tried nukeproof's workaround here: https://github.com/rails/rails/issues/31419 without success. Any suggestions?

Posted in CMS in Rails

re: I'd be interested if people wanted to build an engine like thing to go after WordPress

check out http://camaleon.tuzitio.com/ the UI for it is essentially a clone of WordPress's admin panel