{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "
\n", " \n", " \n", " \n", "
" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "# Pretty Json Viewer\n", "\n", "Json viewer using as underlying module the external package [json-formatter](https://azimi.me/json-formatter-js/)\n" ] }, { "cell_type": "code", "execution_count": 1, "metadata": {}, "outputs": [ { "data": { "text/html": [ "\n", "\n", "\n", "\n", "\n", "
\n", "\n", "" ], "text/plain": [ "" ] }, "execution_count": 1, "metadata": {}, "output_type": "execute_result" } ], "source": [ "from epyk.core.Page import Report\n", "from epyk.tests import data_urls\n", "\n", "rptObj = Report()\n", "# retrieve some random json data\n", "data_rest = rptObj.py.requests.csv(data_urls.BLOG_OBJECT)\n", "j = rptObj.ui.json(data_rest, height=(100, 'px'))\n", "\n", "# change the default options\n", "j.options.open = False\n", "j.options.hoverPreviewEnabled = True\n", "\n", "rptObj.outs.jupyter()" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "[Go back to the tutorials page](../../tutorials.ipynb)\n", "\n", "
\n", "Do not forget that this is a collaborative framework so do not hesitate to give feedbacks and like the different repository to get more visbility.\n", "\n", "Also any help is more than welcome !" ] } ], "metadata": { "kernelspec": { "display_name": "Python 3", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.8.2" } }, "nbformat": 4, "nbformat_minor": 4 }