{ "info": { "author": "Alex Gleason", "author_email": "alex@alexgleason.me", "bugtrack_url": null, "classifiers": [ "Environment :: Web Environment", "Framework :: Django", "Intended Audience :: Developers", "Operating System :: OS Independent", "Programming Language :: Python", "Topic :: Internet :: WWW/HTTP", "Topic :: Internet :: WWW/HTTP :: Dynamic Content" ], "description": "Wagtail Dependencies\n====================\nThis package for Wagtail makes it easy to manage front-end dependencies for admin plugins.\n\n#### The problem\nMultiple Wagtail plugins may require the same front-end dependency, ex. Font Awesome. But we don't want to require that dependency twice on the admin screen, so we need to detect that duplication and only include it only once.\n\n#### The solution\nWe can use named dependencies to prevent duplication, as long as developers can agree to use the same name. For instance, if we name Font Awesome `fontawesome`, then multiple projects can enqueue the `fontawesome` CSS, and this app will be sure it's only imported once.\n\nUsage\n-----\nAdd `wagtaildependencies` to your `INSTALLED_APPS`, then you can use the following hooks:\n\n* `enqueue_scripts`\n* `enqueue_styles`\n\nThe system will automatically detect duplicates among enqueued media throughout apps and will only include the library once.\n\nExample\n-------\n```python\n@hooks.register('enqueue_scripts')\ndef enqueue_jquery():\n return {\n 'jquery': {\n 'source': 'lib/js/jquery.js',\n 'version' '3.1.0',\n }\n }\n\n@hooks.register('enqueue_styles')\ndef enqueue_fontawesome():\n return {\n 'fontawesome': {\n 'source': 'lib/css/fontawesome.css',\n 'version': '4.6.3',\n }\n }\n```", "description_content_type": null, "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/alexgleason/wagtaildependencies", "keywords": "d,e,v,e,l,o,p,m,e,n,t", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "wagtaildependencies", "package_url": "https://pypi.org/project/wagtaildependencies/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/wagtaildependencies/", "project_urls": { "Homepage": "https://github.com/alexgleason/wagtaildependencies" }, "release_url": "https://pypi.org/project/wagtaildependencies/0.0.0/", "requires_dist": [ "wagtail (>=1.4.0)", "Django (>=1.7.1)" ], "requires_python": "", "summary": "Makes it easy to manage front-end dependencies for Wagtail admin plugins", "version": "0.0.0" }, "last_serial": 2252483, "releases": { "0.0.0": [ { "comment_text": "", "digests": { "md5": "282f084ea34d686b6c4dcbf8d44b5d44", "sha256": "1efecdadc075e9bf42ae01add75df237c2710b49dd48b4cc1ba074d887d28c09" }, "downloads": -1, "filename": "wagtaildependencies-0.0.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "282f084ea34d686b6c4dcbf8d44b5d44", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 4258, "upload_time": "2016-07-30T08:06:13", "url": "https://files.pythonhosted.org/packages/75/c9/26fc9560353b119e73def293225b9c5c6d94f5f9a91812168b0dee826969/wagtaildependencies-0.0.0-py2.py3-none-any.whl" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "282f084ea34d686b6c4dcbf8d44b5d44", "sha256": "1efecdadc075e9bf42ae01add75df237c2710b49dd48b4cc1ba074d887d28c09" }, "downloads": -1, "filename": "wagtaildependencies-0.0.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "282f084ea34d686b6c4dcbf8d44b5d44", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 4258, "upload_time": "2016-07-30T08:06:13", "url": "https://files.pythonhosted.org/packages/75/c9/26fc9560353b119e73def293225b9c5c6d94f5f9a91812168b0dee826969/wagtaildependencies-0.0.0-py2.py3-none-any.whl" } ] }