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

Require tablesort.js inside sorts (for webpack compability) #208

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/sorts/tablesort.date.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
var Tablesort = require("../tablesort.js")

// Basic dates in dd/mm/yy or dd-mm-yy format.
// Years can be 4 digits. Days and Months can be 1 or 2 digits.
(function(){
Expand Down
2 changes: 2 additions & 0 deletions src/sorts/tablesort.dotsep.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
var Tablesort = require("../tablesort.js")

// Dot separated values. E.g. IP addresses or version numbers.
Tablesort.extend('dotsep', function(item) {
return /^(\d+\.)+\d+$/.test(item);
Expand Down
2 changes: 2 additions & 0 deletions src/sorts/tablesort.filesize.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
var Tablesort = require("../tablesort.js")

// Filesizes. e.g. '5.35 K', '10 MB', '12.45 GB', or '4.67 TiB'
(function(){
var compareNumber = function(a, b) {
Expand Down
2 changes: 2 additions & 0 deletions src/sorts/tablesort.monthname.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
var Tablesort = require("../tablesort.js")

(function(){

Tablesort.extend('monthname', function(item) {
Expand Down
2 changes: 2 additions & 0 deletions src/sorts/tablesort.number.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
var Tablesort = require("../tablesort.js")

(function(){
var cleanNumber = function(i) {
return i.replace(/[^\-?0-9.]/g, '');
Expand Down