davidfig / pixi-scrollbox

a scrollbox built for pixi.js using a masked box that scrolls vertically and/or horizontally with optional scrollbars
https://www.npmjs.com/package/pixi-scrollbox
MIT License
170 stars 33 forks source link

pixi_scrollbox_1.ScrollBox is not a constructor #14

Open notchris opened 4 years ago

notchris commented 4 years ago

Getting: pixi_scrollbox_1.ScrollBox is not a constructor

When using as follows: ` import { ScrollBox } from 'pixi-scrollbox'; this.app = new PIXI.Application({ backgroundColor: 0x1099bb, width: this.width, height: this.height });

this.viewport = new ScrollBox({ boxWidth: this.width, boxHeight: this.height}); this.container.appendChild(this.app.view); this.app.stage.addChild(this.viewport); `

davidfig commented 4 years ago

What version of scrollbox are you using?

notchris commented 4 years ago

@davidfig I pulled the latest from npm

davidfig commented 4 years ago

Hmm...I just tried it locally and it works. Are you using webpack for your build system? Does importing pixi.js work?

systemrot commented 4 years ago

it guess happens just because class Scrollbox hasn't "B" character. I made and issue about that. Types and sources have different letters (upperCase a lowerCase )