{
"info": {
"author": "",
"author_email": "synwe@yahoo.com",
"bugtrack_url": null,
"classifiers": [
"Development Status :: 4 - Beta",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.6",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Software Development :: Libraries :: Python Modules"
],
"description": "Django Sfp\n==========\n\nServe flat pages for a Vuejs frontend\n\n* **Fast**: no database hits\n* **Safe**: keep the pages in a version control system\n* **Friendly**: edit the pages in an IDE\n* **Cache**: client-side cache thanks to [Apollo client](https://www.apollographql.com/)\n\nInstallation\n------------\n\n``pip install django-sfp``\n\nConfiguration\n-------------\n\n1. Add ``\"sfp\",`` to your ``INSTALLED_APPS``\n\n2. Declare the graphql schema in settings:\n\n ```python\n GRAPHENE = {\n 'SCHEMA': 'sfp.schema.schema',\n }\n ```\n\n3. Add the graphql endpoint url:\n\n ```python\n from django.views.decorators.csrf import csrf_exempt\n from graphene_django.views import GraphQLView\n\n urlpatterns = [\n # ...\n url(r'^graphql', csrf_exempt(GraphQLView.as_view())),\n ]\n ```\n\n4. Install the frontend:\n\nGrab the `Page.vue` component:\n\n ```bash\n wget https://raw.githubusercontent.com/synw/django-sfp/master/frontend/src/components/Page.vue\n ```\n\nInstall the dependencies:\n\n ```\n npm install --save vue-apollo // or vue add apollo if you use vue-cli\n npm install --save @fortawesome/fontawesome-svg-core\n npm install --save @fortawesome/free-solid-svg-icons\n npm install --save @fortawesome/vue-fontawesome\n ```\n\nFont-Awesome is for the spinner loading icon (only this icon will be included in the build, \nnot the whole lib). Vue-router must be installed\n \n5. Add a frontend generic route:\n\n ```javascript\n import Page from './path/to/my/components/Page.vue'\n\n routes: [\n // ...\n\t {\n\t path: '*',\n\t name: 'Page',\n\t component: Page\n\t },\n ],\n ```\nTo make links: ``