Laravel 5 json响应数组

I followed a tutorial on Laravel and AngularJS and trying to convert a public function to laravel 5. The code is this:

public function store()
    {
        Comment::create(array(
            'author' => Input::get('author'),
            'text' => Input::get('text')
        ));

        return Response::json(array('success' => true));
    }

I converted it with this:

public function store()
    {
        Comment::create(array(
            'author' => Request::get('author'),
            'text' => Request::get('text')
        ));
    }

Now, how about the line return Response::json(array('success' => true))? How can I convert it to Laravel 5? Thank you.

Not sure what you mean by converting to Laravel 5, this line of code itself is valid Laravel 5 code, but you can leverage nice helper function Laravel 5 provides:

return response()->json([
    'success' => true
]);