Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

crawlable

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

crawlable

  • 0.0.1.8
  • Rubygems
  • Socket score

Version published
Maintainers
1
Created
Source

Crawlable

Super DRY Sitemaps for Rails and Sinatra Apps (works on Heroku!)

Usage

Install

sudo gem install crawlable

Sitemap (config/sitemap.rb)

Sitemap "http://www.example.com" do
  link articles_path, :priority => 0.7, :changes => 'daily'
  
  Post.all.each do |a|
    link articles_path(a), :updated_at => a.updated_at do
      image images_path(a.featured_image)
    end
  end
end
Result
<?xml version="1.0"?>
<urlset>
  <url>
    <loc>/articles</loc>
    <lastmod>2010-06-20T09:38:26+00:00</lastmod>
    <changefreq>daily</changefreq>
    <priority>0.7</priority>
  </url>
  <url>
    <loc>/articles/title-0</loc>
    <lastmod>2010-06-20T09:38:26+00:00</lastmod>
    <changefreq>weekly</changefreq>
    <priority>0.5</priority>
  </url>
  <url>
    <loc>/articles/title-1</loc>
    <lastmod>2010-06-20T09:38:26+00:00</lastmod>
    <changefreq>weekly</changefreq>
    <priority>0.5</priority>
  </url>
  ...
</urlset>

Feed

Feed do
  title "My RSS Feed"
  author "Lance Pollard"
  description "Something nice and tidy"
  
  Post.all.each do |a|
    entry "/posts/#{a.to_param}", :updated_at => a.updated_at, :title => a.title
  end
end

Features

  • Works on Heroku
  • Pings Google, Bing, Yahoo!, and Ask whenever anything changes

Alternatives

  • SitemapGenerator
  • Sitemap
  • BigSitemap
  • Sitemap (diff than above)
  • SitemapGenerator (diff than above)
  • Sitemapper

Resources

FAQs

Package last updated on 02 Jul 2010

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc