Classical 0.1.11

A TypeScript Base Class Library.

There is a newer version of this package available.
See the version list below for details.
Install-Package Classical -Version 0.1.11
dotnet add package Classical --version 0.1.11
<PackageReference Include="Classical" Version="0.1.11" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add Classical --version 0.1.11
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

Release Notes

- The Watch.js polyfill was added to classical.js.
- The MutationObserver.js polyfill was added to classical.js
- JsMin was used to minify classical.js
- Added Intro.ts for getting started
- Added a minified version of classical.js: classical.min.js
- Added two methods to the Type class in Reflection
- getFieldsOf
- getFieldOf
- All tests continue to pass

//Write your first few lines of Classical.js
module Classical.Introduction {

   import Assert = Classical.Assert;
   import Expression = Classical.Expression;
   import u = Utilities;
   import r = Classical.Reflection;
   import e = Classical.Events;
   import b = Classical.Binding;
   import cc = Classical.Collections;
   import bc = Classical.Binding.Collections;

   //1. Read through the Classical.js code below
   //2. Inspect the results in the browser console
   //3. Explore each of the modules above using intellisense
   //4. Have fun!

   //Array extensions
   export var array = []
   .add(0).add(0.5).add(1)
   .addRange([1.5, 2, 2.5])
   .set(6, 3)
   .query()
   .concat(
   cc.Enumerable
   .range(3.5, .5, 10))
   .where(x => x < 5)
   .select(x => Math.round(x * 2))
   .array();

   //Query Comprehension
   export var aggregation =
       array.query()
       .sum(x =>
           Math.pow(Math.sin(x), 2) +
           Math.pow(Math.cos(x), 2)) /
       array.length;

   //Query Information
   export var queryType = typeOf(cc.Queryable);
   export var queryMethods = queryType
       .getMethods(r.Modifier.Public, r.Modifier.Instance)
       .dictionary(
           m => m.name,
           m => u.format('{0}({1})',
               m.name,
               m.getParameters()
               .select(p => p.name)
               .array()));

   //Reflection Classes
   export var reflectionModule = moduleOf(r.Type);
   export var reflectionClasses = reflectionModule
       .getTypes().select(t => t.name)
       .array();

   //Type Members
   export var typeType = queryType.getType();
   export var typeMembers = typeType
       .getProperties(r.Modifier.Public, r.Modifier.Instance, r.Modifier.Static)
       .select(m => m.name)
       .array();
}

Dependencies

This package has no dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version History

Version Downloads Last updated
0.3.1 902 8/23/2015
0.3.0 670 7/18/2015
0.2.19 662 2/19/2015
0.2.18 580 2/18/2015
0.2.17 642 2/18/2015
0.2.16 615 2/18/2015
0.2.15 653 2/18/2015
0.2.14 645 1/28/2015
0.2.13 624 1/28/2015
0.2.12 648 1/28/2015
0.2.11 646 1/28/2015
0.2.10 593 1/28/2015
0.2.9 611 1/12/2015
0.2.8 663 1/12/2015
0.2.7 575 1/12/2015
0.2.6 660 1/12/2015
0.2.5 643 1/12/2015
0.2.4 625 1/12/2015
0.2.3 666 1/12/2015
0.2.2 661 1/12/2015
0.2.1 620 1/11/2015
0.2.0 620 1/11/2015
0.1.14 593 1/8/2015
0.1.13 695 12/24/2014
0.1.12 590 12/22/2014
0.1.11 643 12/21/2014
0.1.10 603 12/21/2014
0.1.9 600 12/20/2014
0.1.8 617 12/20/2014
0.1.7 575 12/20/2014
0.1.6 612 12/20/2014
0.1.5 622 12/19/2014
0.1.4 603 12/19/2014
0.1.3 593 12/19/2014
0.1.2 637 12/16/2014
0.1.1 592 12/16/2014
0.1.0 652 12/16/2014
Show less