Skip to content

This library intends to support JSON Feed in Django and feedgenerator.

License

Notifications You must be signed in to change notification settings

myles/django-jsonfeed

Repository files navigation

Django-JSONFeed

This library intends to support JSON Feed in Django and feedgenerator.

Django JSONFeed

Usage

If you are using Django:

from django.contrib.syndication.views import Feed
from jsonfeed import JSONFeed

class ExampleFeed(Feed):
    type = JSONFeed

If you are using this library without Django, you will first need to install the feedgenerator Python package:

from jsonfeed import JSONFeed

feed = JSONFeed(
    title='Hello, World!',
    link='https://example.com/',
    language='en'
)

feed.add_item(
    title='One',
    link='https://example.com/1/',
    pubdate=datetime(2018, 2, 28, 15, 16)
)

return feed.writeString()

Installation

$ pip install django-jsonfeed

About

This library intends to support JSON Feed in Django and feedgenerator.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages