Encore\Admin\Tree::render PHP Method

render() public method

Render a tree.
public render ( ) : Illuminate\Http\JsonResponse | string
return Illuminate\Http\JsonResponse | string
    public function render()
    {
        if (Request::capture()->has('_tree')) {
            return response()->json(['status' => $this->saveTree(Request::capture()->get('_tree'))]);
        }
        $this->buildupScript();
        AdminManager::script($this->script);
        view()->share(['path' => $this->path]);
        return view('admin::tree', $this->variables())->render();
    }