var data = {!!json_encode($collection, JSON_UNESCAPED_SLASHES|JSON_HEX_APOS)!!};
@json
var data = @json($collection);
Pro tip: use ```triple backticks around text``` to write in code fences