Security News
Fluent Assertions Faces Backlash After Abandoning Open Source Licensing
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
jquery-ellipsis
Advanced tools
simple jquery plugin that excerpts text depending on lines or characters number.
Download using one of the following Methods
$ npm install --save jquery-ellipsis
$ bower install --save ellipsis
please be sure to includejquery >= 2.x
then include ellipsis:
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.0.0/jquery.min.js"></script>
<script src="path/to/jquery.ellipsis.min.js"></script>
ellipsis can be used in two different ways:
via data
attributes.
<p data-toggle="ellipsis" data-type="chars" data-count="150"> Amet id nisi ipsa pariatur eaque aperiam dolorum eius quia, vero provident? Doloremque impedit at cupiditate illum magnam, quo, vel corrupti. Esse voluptates hic vitae porro temporibus temporibus! Possimus rem.</p>
manual way:
<p id="ellipsis_me">Amet id nisi ipsa pariatur eaque aperiam dolorum eius quia, vero provident? Doloremque impedit at cupiditate illum magnam, quo, vel corrupti. Esse voluptates hic vitae porro temporibus temporibus! Possimus rem.</p>
<script>
$(document).ready(function() {
$('#ellipsis_me').ellipsis(options);
});
</script>
option | type | value |
---|---|---|
type | String | determines type is whetherchars or lines number that the text should be excerpted. |
count | Number | determines the number of chars or lines should the text be excerpted. |
event | when |
---|---|
initialize.ellipsis | before the initialization of the plugin |
initialized.ellipsis | after the initialization. |
excerpt.ellipsis | before excerpt the text |
excerpted.ellipsis | after the text being excerpted |
update.ellipsis | before updating when window is resized |
updated.ellipsis | after updating. |
$('#paragraph').on('initialize.ellipsis', function() {
// do some stuff
});
two different types of excerpts by lines/characters
Support re-adjust option later.
different custom event through the life cycle of the plugin.
Destroyable.
data attribute automatic init.
Up comming!
...
FAQs
ellipsis text depending on number of lines or number of chars
The npm package jquery-ellipsis receives a total of 233 weekly downloads. As such, jquery-ellipsis popularity was classified as not popular.
We found that jquery-ellipsis demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
Research
Security News
Socket researchers uncover the risks of a malicious Python package targeting Discord developers.
Security News
The UK is proposing a bold ban on ransomware payments by public entities to disrupt cybercrime, protect critical services, and lead global cybersecurity efforts.