Skip to content

moved resized and scrolled into constructor#10

Closed
rosenbjerg wants to merge 1 commit intodevelopit:masterfrom
rosenbjerg:master
Closed

moved resized and scrolled into constructor#10
rosenbjerg wants to merge 1 commit intodevelopit:masterfrom
rosenbjerg:master

Conversation

@rosenbjerg
Copy link

moved resized and scrolled into constructor so that the ScrollViewport-component is usable without class property transformation. It should not increase the final size since the transformation creates the same result

moved resized and scrolled into constructor so that the ScrollViewport-component is usable without class property transformation
@rosenbjerg
Copy link
Author

Shouldn't really be necessary, but I get this error:

[!] (buble plugin) SyntaxError: Unexpected token (21:9)
node_modules\preact-scroll-viewport\src\index.js (21:9)
17 :  *      sync
18 :  *    />
19 :  */
20 : export default class ScrollViewport extends Component {
21 :   resized = () => {

So perhaps the version published on npm has the properties "untransformed" ?

@rosenbjerg
Copy link
Author

The problem seems to be that I was importing the src/index.js instead of dist/preact-token-input.js, since i was just using import TokenInput from 'preact-token-input';. So it clearly resolved the wrong file, but that has nothing to do with this library, so i will close this again.

@rosenbjerg rosenbjerg closed this Aug 27, 2018
@developit
Copy link
Owner

Thanks for updating when you found the solution @rosenbjerg!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants