baron icon indicating copy to clipboard operation
baron copied to clipboard

Base structure

Open rustam87 opened this issue 6 years ago • 2 comments

Man, please create base structure of baron and add to tutorial. I have been workiing with baron already two hours and dont understanding how it works. For example HTML

<div class="baron">
        <div class="baron__scroller"></div>
</div>

bla bla bla CSS

.baron{}
.baron_scroller{}

bla bla bla

only rules that real needing for initialize baron

JS

baron({
   scroller: ''
});

only options that real needing for initialize baron

Thanks

rustam87 avatar Dec 26 '17 13:12 rustam87

Same stuff for me)

Safe-Mode avatar Feb 25 '18 10:02 Safe-Mode

HTML

 <div id="baron_1" class="baron baron__root baron__clipper _simple">
  <div class="baron__scroller">
      // Your content
  </div>
  <div class="baron__track">
          <div class="baron__bar"></div>
  </div>
 </div>

CSS you need @import "~baron/skins/styles.css" and select one of 3 classes(for example baron__clipper _simple like this) and your element(in this example element with id=#baron_1 must have a height, for example 300px

JS

baron({
     scroller: `#baron_1`,
     track: `.baron__track`,
     bar: `.baron__bar`
});

rustam87 avatar Feb 25 '18 18:02 rustam87