GitXplorerGitXplorer
c

rome-rails

public
1 stars
0 forks
0 issues

Commits

List of commits on branch master.
Unverified
a4bce7e0c5e0eff29242c2416620354c844661d4

Update README.md

ccllns committed 9 years ago
Unverified
5c1b65523d8756dbc742083c510657001ef16968

Update README.md

ccllns committed 9 years ago
Unverified
fc6c5599e97d53d0d89ed5df4a94ba1c43d54bf6

Update README.md

ccllns committed 9 years ago
Unverified
70b8686d65a13833f6496bd5e245f2d21fafa84b

Release v2.1.22 (first release for this gem)

ccllns committed 9 years ago
Unverified
9748d2acf5e7bd72d46064e860a290051e5b59ce

Initial commit (blank gem)

ccllns committed 9 years ago

README

The README file for this repository.

rome-rails

rome-rails wraps the Rome (GitHub) javascript library for use in a Ruby on Rails project.

Rome is a customizable date (and time) picker.

Rome depends on moment, which is bundled by default. If you're already using moment, you can use a version of Rome that doesn't bundle moment.

It doesn't depend on jQuery or other frameworks, though.

Usage

Add the following to your Gemfile:

gem "rome-rails"

Bundled version (includes moment)

Rome rails includes a bundled version of moment.js.

Add the following directive to your Javascript manifest file (application.js):

//= require rome

Standalone version (uses existing moment)

If you're already using moment, (perhaps with the momentjs-rails gem?) you can included a standalone version of Rome.

Just make sure you require moment before rome-standalone in your Javascript manifest file (application.js).

//= require moment
//= require rome.standalone

Stylesheets

Add the following directive to your Stylesheets manifest file (application.css):

//= require rome

If you're using sass-rails, and your manifest file is application.**scss**, then you should use Sass's style @import functions

@import "rome";

Creating a calendar

Once you have the files required, write some javascript (likely in a new file) to create a calendar.

Follow the examples from the rome homepage.

Remember: rome doesn't require jQuery, so it takes a native DOM element, not a jQuery element.

Versioning

The version of this gem will match the version of the underlying Rome library.

Development

After checking out the repo, run bundle to install dependencies. Then, run rake spec to run the tests.

Contributing

Bug reports, pull requests, support queries are welcome on GitHub at https://github.com/cllns/rome-rails. This project actively pursues maintaining a safe, welcoming space for collaboration, and contributors are expected to adhere to the Contributor Covenant code of conduct.

License

The gem is available as open source under the terms of the MIT License.