Skip to content

Releases: dibiancoj/Linq4Javascript

Order By Case Sensitive

07 Sep 19:29
Compare
Choose a tag to compare

Fixed an issue where the order by statements didn't take case into account for string data types.
ie: "AA" vs "aa" isn't being treated equally.

Typescript 2.1.4 Release And ReadonlyArray

09 Dec 02:32
Compare
Choose a tag to compare

This release was made to handle Typescript 2.1.4 and readonly arrays. Added an interface so you can use Linq4Javascript off of this array type in Typescript.

 var _array: ReadonlyArray<number> = Object.freeze([1,2,3,4]);

 var results = _array.Where(x => x == 2).ToArray();

Added GroupJoin and DefaultIfEmpty methods

10 Jun 20:53
Compare
Choose a tag to compare

Added the following methods

  1. GroupJoin
  2. DefaultIfEmpty

Please see the documentation or unit tests for more detail on how to use the new methods.

I will try to batch the releases better going forward.

Added Join Method. Removed ConcatQuery and UnionQuery

09 Jun 02:01
Compare
Choose a tag to compare

IMPORTANT: Removed ConcatQuery and UnionQuery. Please just use Concat and Union for all scenarios (either an array or query to be concat or union). Sorry for the inconvenience.

Added the join method
Join(OuterArray Or Query, function(I): InnerTablePropertySelector, function(O): OuterTablePropertySelector, function(I,O): Creates the join record where I is the inner table and O is the outer table. Description: Will join 2 datasets by a key and will create a new row based on the 2 records that match. Similar to a Sql inner join Example:

var mySkipWhileResult= _Array.Join(_OuterArray, x => x.Id, y => y.Id, (x,y) => { Id: x.Id, StateName: y.Description);

Note: Not supported in async mode yet.

** No fixes were made in this release. If you don't need the join method then you don't need to upgrade.

ElementAt And ElementAtDefault

01 Jun 19:43
Compare
Choose a tag to compare

Added 2 methods.

  1. ElementAt(Index): T was added to the API. Pass in the index number and the element sitting at that position will be returned. If the index is greater then the array or query count an error will be returned.
  2. ElementAtDefault(Index): T was also added to the API. Pass in the index number and the element sitting at that position will be returned. If the index is greater then the array or query count null will be returned.

Typescript 1.8 Breaking Change

08 Apr 22:34
Compare
Choose a tag to compare

It appears Microsoft had a breaking change with Typescript 1.8. microsoft/TypeScript#3876

This caused Linq4Javascript to throw errors when trying to compile in Typescript.

Async

01 Jul 19:48
Compare
Choose a tag to compare

Add the ability to run a query without locking the UI on long running queries.

Async is used to offload any query off of the UI thread to prevent freezing and slowness on the site. The implementation uses Html 5 Web Workers. If a user is using an older browser, JLinq will fallback to the normal ToArray() method to complete the query results.

Please see the wiki page for full documentation on the syntax.

Move To Git Hub

19 Jun 18:35
Compare
Choose a tag to compare

Moved From Code Plex To Git Hub: (https://linq4javascript.codeplex.com/)

-Removed 2 deprecated method. LastItem() & AnyItems. Use Last() / Any() for the equivalent methods.
-Added AsQueryable() as an extension method off of an Array. Makes it easier to do the following:

 ie: var query = List.AsQueryable();

 if (filter1 != null)
 {
      query = query.Where(function(x .....))
 }

 if (filter2 != null)
 {
      query = query.Where(function(x......))
 }

 //grab the results
 var results = query.ToArray();