Hide the stripe details passed to view in laravel
I am using stripe for payment purposes. Here the thing is that I am passing my stripe key and oauth token to the view in following way: The controller part return view($filepath, [ 'stripe_key' => $this->getApiKey($project), 'oauth_token' => $project->stripe_oauth_token, ]); and inside my view i am using it as @if( !empty($oauth_token) ) const stripe = Stripe("{{ $stripe_key }}", { stripeAccount: "{{ $oauth_token }}" }); @else const stripe = Stripe("{{ $stripe_key }}") @endif How can I secure it in terms that they can be use as well as not shown in the client side. Currently i did was to encod
0 upvotes
View original discussion ↗
Comments
Sign in or sign up to comment and upvote.
No comments yet.