Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clamp fails if element style is undefined #64

Open
theothertored opened this issue Dec 7, 2017 · 3 comments
Open

Clamp fails if element style is undefined #64

theothertored opened this issue Dec 7, 2017 · 3 comments

Comments

@theothertored
Copy link

Title says it all.

Uncaught TypeError: Cannot read property 'webkitLineClamp' of undefined
    at clamp (clamp.js:32)
@aaroncolon
Copy link

You must pass a single element

@PaykomanVll
Copy link

I think he has modified the script, the script check the browser can use webkitLineClamp or not, so that is this error confused...

@ZooTopiaGG
Copy link

you can forEach element array
elementArray.forEach(x => {
$clamp(x, { clamp: 2 })
});
but I think the performance is bad

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

No branches or pull requests

4 participants