Posts 0.1.0: Posts, groups, tags and scheduled publishing for PhoenixKit
Posts 0.1.0 is the first release of the PhoenixKit Posts module. It gives a Phoenix site posts with drafts and scheduled publishing, pictures, tags, groups, likes, mentions and view counts, managed from the PhoenixKit admin.
What a post has
A post has a title, a subtitle, content and a slug made from the title. It is one of three types: post, snippet or repost. Its status is draft, public, unlisted or scheduled; a scheduled post is published at its time by a background job. A post can have several pictures in an order, the first being the featured one, and hashtags, user mentions, likes and dislikes, and a view counter.
Posts can be collected into groups, boards a user keeps for their own posts, in an order of their choosing.
In the admin
The module adds a Posts section to the admin, with All Posts, Groups and New Post. The posts list has a search box and filters by type, status and group, and lets you publish, delete or add several posts to a group at once. A post’s own page shows its content, its counts and a Like button. Groups have their own list and form.
The settings page under Settings sets limits for media, title, subtitle, content, mentions and tags, the number of posts per page and the default status of a new post. It switches likes, scheduling, groups, reposts, automatic slugs and view counts on or off, and can require approval before a post goes public.
Upgrading
Posts 0.1.0 needs PhoenixKit 1.7 and the Comments module 0.1. Add {:phoenix_kit_posts, "~> 0.1.0"} and run mix deps.get; the module shows up in the admin by itself. Its tables come from PhoenixKit core’s migrations, so there is nothing else to run.
Posts 0.1.0. Install or update: {:phoenix_kit_posts, "~> 0.1"}, then mix deps.get && mix phoenix_kit.update. Full history: CHANGELOG.