【问题标题】:Gem for Creating a full featured Blog in Rails Application [closed]用于在 Rails 应用程序中创建功能齐全的博客的 Gem [关闭]
【发布时间】:2014-01-27 18:15:08
【问题描述】:

我需要一个 gem 来在我的 rails 应用程序中创建博客。 我们可以编写一大堆代码,但对于这个小任务,最好使用有效的 Gem。 请推荐一个好的 Gem 来创建一个支持以下功能的博客:

- Adding static  Blog contents. 
- Feature to have image in blog
- Visitor/Viewer must be able to comment/share the blog 
 ( will be much nicer if can be commented/shared via Facebook account)

我通过 Gems 喜欢:

-  "Redcloth" (for creating static web pages quickly; quite unsure 
    will it be able to handle image & comment facility. )
-  Gem "dynarex-blog" (for creating blog, but unable to find 
   good tutorial / proper documentation for integrating it with my Application).

【问题讨论】:

标签: ruby-on-rails gem blogs redcloth


【解决方案1】:

以下是您可能受益的更多资源:

教程

宝石


博客

如果我要创建一个简单的博客应用程序,我会这样做:

  1. 创建PostCategoryTagCommentImage 模型

  2. 在路由中使用 Slugalicious 以路由到具有如下路由的帖子:domain.com/blog/your-post-title

  3. 添加管理区域(可能使用ActiveAdmin || RailsAdmin),但您可能希望使用this tutorial 创建自己的管理区域

  4. 我会使用所见即所得(例如Redactor)在管理区域中创建帖子。查看 Petekun 的帖子,我建议使用降价格式结构(保持一切干燥)

  5. 使用CanCan 来确定哪些用户角色可以编写 cmets 等

  6. 图片可以使用PaperclipCarrierwave上传

【讨论】:

  • 前两个链接无法访问
  • 我认为 CanCan 已被弃用,取而代之的是 CanCanCan
【解决方案2】:

假设您已经准备好一个应用程序,并希望尽快向其中添加一个非常小的“博客”,

如果您只是想要一个简单但相对较重的解决方案,请查看:

(来源:A clean minimal gem to add a simple blog to existing app? [closed]

【讨论】:

    【解决方案3】:

    您需要的是https://github.com/jipiboily/monologue。它是满足您所有要求的一颗宝石。要覆盖源,只需将内容复制到您的 rails 应用程序文件夹即可。因此,您可以使用自己的风格和逻辑。

    【讨论】:

      【解决方案4】:

      您可能会喜欢https://github.com/mixandgo/simple_blog。它没有从您的主应用程序中获得命名空间,因此您只需将其作为现有 Rails 应用程序的一部分插入即可。

      【讨论】:

        猜你喜欢
        • 2011-01-22
        • 2012-03-29
        • 1970-01-01
        • 1970-01-01
        • 2011-05-07
        • 1970-01-01
        • 2012-10-17
        • 1970-01-01
        • 1970-01-01
        相关资源
        最近更新 更多