Christmas Tree

A lightweight Christmas tree generator for JavaScript

usage

  • clone or download repository
  • open christmasTree.js in a modern text editor such as VSCode
  • turn head sideways
  • experience the joy of the season

example uses:

browser

function ChristmasTreeFarm(numberTrees) {
	farm = '';
	for(i=0; i < numberTrees; i++) {
		farm += (ChristmasTree.toString())
	}
	return farm;
}
console.log(ChristmasTreeFarm(1000));

text editor

VSCode

known limitations

  • does not work in IE9
  • minification may impact functionality