Giter Club home page Giter Club logo

bootstrap4-datetime-picker-rails's Introduction

bootstrap4 datetime picker rails

Makes Tempus Dominus available to your rails appliation through the asset pipeline.

Usage Instructions

Add the following to your Gemfile and then run bundle

gem 'bootstrap4-datetime-picker-rails'

Add the following to application.js

//= require moment
// If you require timezone data (see moment-timezone-rails for additional file options)
//= require moment-timezone-with-data
//= require tempusdominus-bootstrap-4

Add the following to application.scss

@import "tempusdominus-bootstrap-4";

Or

*= require tempusdominus-bootstrap-4

If you are not using Sass, add the following to your application.css

/*
...
*= require tempusdominus-bootstrap-4
...
*/

Localizations

The Tempus Dominus datepicker exposes Moment.js localizations. A list of available Moment localizations are found here.

Select which JavaScript file you want to use and then add the following line in application.js

//= require moment/<locale>.js

Then, where your datepicker is configured (such as a .coffee file), add the following configuration option:

$(#datetimepicker).datetimepicker
  locale: 'de'

Update Instructions

Change the checkout_branch variable in Rakefile to the version.

Change the versions in lib/bootstrap4_datetime_picker_rails/version.rb

Run bundle exec rake update

Commit with 'Update to $VERSION release'

Run git push

Run bundle exec rake build to confirm a successful build

Run bundle exec rake publish to publish to rubygems (automatically creates and pushes a tag to git)

Create a release on GitHub with the new gem version

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.