mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-08-16 23:10:29 +00:00
make tests
This commit is contained in:
@@ -1,5 +1,14 @@
|
||||
/// <reference path="./jquery-truncate-html.d.ts" />
|
||||
|
||||
jQuery('<p>Stuff and <i>Nonsense</i></p>').truncate({
|
||||
length: 13
|
||||
}).html();
|
||||
|
||||
function truncateHtmlString(): string {
|
||||
return $.truncate('<p>Stuff and <i>Nonsense</i></p>', {
|
||||
length: 13
|
||||
});
|
||||
}
|
||||
|
||||
function truncateVirtualElement (): JQuery {
|
||||
return $('<p>Stuff and <i>Nonsense</i></p>').truncate({
|
||||
length: 13
|
||||
});
|
||||
}
|
||||
|
||||
+2
-2
@@ -13,8 +13,8 @@ interface ITruncateOptions{
|
||||
ellipsis?: string;
|
||||
}
|
||||
|
||||
interface jQuery{
|
||||
truncate(options: ITruncateOptions) : jQuery;
|
||||
interface JQuery{
|
||||
truncate(options: ITruncateOptions) : JQuery;
|
||||
}
|
||||
|
||||
interface JQueryStatic {
|
||||
|
||||
Reference in New Issue
Block a user