npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

taiji

v0.1.0

Published

taiji language

Downloads

6

Readme

Taijilang

introduction

Taijilang is a new powerful general programming language. Taijilang have more extensibility and customizability than all other existing programming languages.

In general, the features of Taijilang can be summed up: more useful macro than in lisp, more important white space in syntax than in python, more general preprocess than in C, more powerful meta compilation than metalua, more flexible dialect than rebol, more optimized object code than in coffee-script.

features

  • Compiled to javascript language
  • Flexible friendly syntax with attaching great importance to indent and white spaces,

e.g. white space can change the precedence of operator, see the examples below:

1+2*3 // same as 1 + (2*3)
1+2 * 3 // same as (1+2) *3
(1 + 2
* 3 + 4) // same as (1+2) * (3+4)
  • Everything are expressions
  • Macro in lisp style

Based on back quoted list, Taijilang have macro simliar to lisp. Combined with a friendly, extendable dynamic syntax, macro in Taijilang becomes even more powerful than in lisp:

/. "/." starts an indent block comment, which stops until meeting an undent.
  taijilang implements macro in lisp style, but with different symbol in accordance with  traditional grammar, e.g.
  "~" equal to "'" in lisp, "`" is the same as in lisp, ^" eqaul to "," in lisp, "^&" equal to ",@" in lisp
// below is a macro definition
// line comment can lead a indented code block
  // do is a predefined keyword, we add \ before it to escape the meaning
  \do #= (body..., clause) -=>
    if clause[0]=='where' then
      `{let ^&(clause.slice(1)) then ^&body}
    else if clause[0]=='when' then
      `{doWhile! ^clause[1] ^&body}
    else if clause[0]=='until' then
      `{doWhile! not(^clause[1]) ^&body}
  // now the code below becomes valid:
    do 
      print a
      print b 
    where a=1, b=2
    i = 0; do print i++ until i==10
  
  • Meta Language

Any expression can be evaluated in the compiling time, so taijilang become the meta language of itself.

below is some samples to demonstrate the meta language features, e.g.

// #1+2 and #3+4 is evaluated in compiling time:
  if 1 then #1+2 else #3+4
// the condition of "if" statemeng is evaluated in compiling time
// when the condition is true, "then" clause is compiled, else "else" clause is compiled. 
// this is similar to the #if in C language.
  # if 1 then 1+2 else 3+4
// different from the above sample, the whole "if" statement below is evaluated in the compiling time
  ## if 1 then 1+2 else 3+4
  
  • Most customizable and extensible language, with the help of dynamic parser, macro and meta language features

below is some samples:

// Taijilang use ? as an attribute prefix to access the parser, 
// use ?? and ?/ to evaluate in the parsing time, if use ?/, the prefix ? can be omitted. 
  ?? ?cursor() // put the current parsing position to the compiled code
  ?? ?clause(), print 1 // all parser.clause() to parse the following code
  ?/ clause(), print 1 // call parser.clause() to parse the following code
  • Module and package

  • Optimized object code

    Taijilang completely avoids generating closure function and function call while transforms expressions to javascript construct; delete operation which has no effect; do recursion optimization, including but not limited to tail recursion optimization on((see samles/let.tj), and so on.

Project Address:

github: github.com/taijiweb/taijilang

npm: npmjs.org/chaosim/taiji

google groups: taijilang

G+: taiji lang

QQ群: 太极语言 194928684

Creator

The creator of taijilang is 曹星明( Caoxingming, assumed name 太极真人(Taiji Zhenren) ) [email protected].

contributors

Everyone is welcome to become the contributors.

thanks

Thanks to the people who make the great things, I learned so much from them:

John McCarthy, he invented the great language - Lisp, Taijilang follows the spirit of lisp in the heart.

Jeremy Ashkenas, he created coffee-script. I used to coffee-script to write Tajilang and learned a lot from it on how to create an elegant language and compile it to javascript.

Ryan Dahl, he created node.js, Taijilang runs on node.js.

Santosh Rajan, he created lispyscript, from which I got the original inspiration on how to design Taijilang.

TJ Holowaychuk, he shines the two letter "TJ" because of so many great stuffs he have made, and I am honored to use .tj as the the extension name of taijilang code file.

I need thank many other people and the stuffs made by them, too, although I can not list everyone of them here.

At last, I'll thank to my family.

Let it go, let's start the game of throne, write a song of ice and fire in the taiji language.