From 2576a083c1c8b88be645b8081e9eaae023d3fe1d Mon Sep 17 00:00:00 2001 From: hongymagic Date: Thu, 15 May 2014 10:47:05 +1000 Subject: [PATCH 1/3] Replace git submodules and use bower dependencies instead - Fix #10 (thanks @piacentini) --- .bowerrc | 3 +++ .gitignore | 1 + .gitmodules | 6 ------ .travis.yml | 6 ++---- bower.json | 12 +++++++++--- package.json | 2 +- test/tests.html | 8 ++++---- tools/jquery | 1 - tools/qunit | 1 - 9 files changed, 20 insertions(+), 20 deletions(-) create mode 100644 .bowerrc delete mode 160000 tools/jquery delete mode 160000 tools/qunit diff --git a/.bowerrc b/.bowerrc new file mode 100644 index 0000000..ffede22 --- /dev/null +++ b/.bowerrc @@ -0,0 +1,3 @@ +{ + "directory": "components" +} \ No newline at end of file diff --git a/.gitignore b/.gitignore index 0ca0b3d..da032f1 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ .DS_Store node_modules/ +components/ diff --git a/.gitmodules b/.gitmodules index 79ddfb5..e69de29 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,6 +0,0 @@ -[submodule "tools/qunit"] - path = tools/qunit - url = https://github.com/jquery/qunit.git -[submodule "tools/jquery"] - path = tools/jquery - url = https://github.com/jquery/jquery.git diff --git a/.travis.yml b/.travis.yml index f61a724..d30ba63 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,7 +1,5 @@ language: node_js node_js: - - 0.8 - - 0.9 - - 0.10 + - 0.11 before_script: - - npm install -g grunt-cli + - npm install -g grunt-cli bower diff --git a/bower.json b/bower.json index 5121008..2612443 100644 --- a/bower.json +++ b/bower.json @@ -1,10 +1,16 @@ { "name": "jQuery.serializeObject", "version": "2.0.3", - "main": "jQuery.serializeObject.js", + "main": "jquery.serializeObject.js", "ignore": [ "**/.*", "node_modules", "components" - ] -} \ No newline at end of file + ], + "dependencies": { + "jquery": "1.9.1" + }, + "devDependencies": { + "qunit": "~1.14.0" + } +} diff --git a/package.json b/package.json index bb16761..2e3b0a0 100644 --- a/package.json +++ b/package.json @@ -7,7 +7,7 @@ "test": "test" }, "scripts": { - "pretest": "git submodule update --init --recursive && git submodule foreach --recursive git pull origin master && cd tools/jquery && npm install && grunt", + "pretest": "bower install", "test": "grunt" }, "repository": { diff --git a/test/tests.html b/test/tests.html index 4815cc4..efc21ff 100644 --- a/test/tests.html +++ b/test/tests.html @@ -4,10 +4,10 @@ $.serializeObject tests - - - - + + + + diff --git a/tools/jquery b/tools/jquery deleted file mode 160000 index d511613..0000000 --- a/tools/jquery +++ /dev/null @@ -1 +0,0 @@ -Subproject commit d511613d748a92af04a3f07943f34f9baadc4153 diff --git a/tools/qunit b/tools/qunit deleted file mode 160000 index c319c35..0000000 --- a/tools/qunit +++ /dev/null @@ -1 +0,0 @@ -Subproject commit c319c356cb4942a16ea62e5b9020044e7d97c1b9 From 8a037f1890085f8c7553e8e654f7d243f8bd2bcd Mon Sep 17 00:00:00 2001 From: David Hong Date: Thu, 26 Nov 2015 14:08:58 +1100 Subject: [PATCH 2/3] docs: add known issues section in readme --- README.markdown | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/README.markdown b/README.markdown index d69768a..7407517 100644 --- a/README.markdown +++ b/README.markdown @@ -67,6 +67,8 @@ version 1.0.4 if you require camel casing of names.* - Fix an issue (#2) where arrays longer than 2 resulted in incorrect values +## Known issues -[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/hongymagic/jquery.serializeobject/trend.png)](https://bitdeli.com/free "Bitdeli Badge") +- In rare cases, this won't work with old checkbox/hidden hack. See [this issue for more details](https://github.com/hongymagic/jQuery.serializeObject/issues/9). +[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/hongymagic/jquery.serializeobject/trend.png)](https://bitdeli.com/free "Bitdeli Badge") From bf9502f8d7bb6ab2ee4500550b6b0bbbd14fd19b Mon Sep 17 00:00:00 2001 From: Erik van Velzen Date: Wed, 14 Jun 2017 19:21:39 +0200 Subject: [PATCH 3/3] Add a typescript definition for the library --- jquery.serializeObject.d.ts | 4 ++++ package.json | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-) create mode 100644 jquery.serializeObject.d.ts diff --git a/jquery.serializeObject.d.ts b/jquery.serializeObject.d.ts new file mode 100644 index 0000000..3aea456 --- /dev/null +++ b/jquery.serializeObject.d.ts @@ -0,0 +1,4 @@ + +interface JQuery { + serializeObject(): { [index: string]: string|string[] } +} diff --git a/package.json b/package.json index 2e3b0a0..b07a0b7 100644 --- a/package.json +++ b/package.json @@ -1,8 +1,9 @@ { "name": "jQuery.serializeObject", - "version": "2.0.3", + "version": "2.0.4", "description": "A jQuery plugin to turn form data into JSON", "main": "jquery.serializeObject.js", + "types": "jquery.serializeObject.d.ts", "directories": { "test": "test" },