1

I am trying to implement this date picker https://www.npmjs.com/package/react-16-bootstrap-date-picker I am able to implement this but my date picker is not look like same as show in example .I think my css file is not loaded why ?

here is my code https://codesandbox.io/s/r1ox70mrq

class App extends Component {
  render() {
    return (
      <div>
        ddd
        <DatePicker id="example-datepicker" />
      </div>
    );
  }
}

2 Answers 2

1

Just you need to add bootstrap style to your index.html in your react project like this:

<!-- Latest compiled and minified CSS -->
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">

check demo.

Also you can check this reference for more details.

Sign up to request clarification or add additional context in comments.

Comments

0

You need to add bootstrap css. For reference https://github.com/pushtell/react-bootstrap-date-picker/blob/master/example/app.jsx

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.