How to use the ssf.parse_date_code function in ssf

To help you get started, we’ve selected a few ssf examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github SheetJS / js-harb / harb.flow.js View on Github external
function numdate(v/*:number*/)/*:Date*/ {
	var date = SSF.parse_date_code(v);
	var val = new Date();
	if(date == null) throw new Error("Bad Date Code: " + v);
	val.setUTCDate(date.d);
	val.setUTCMonth(date.m-1);
	val.setUTCFullYear(date.y);
	val.setUTCHours(date.H);
	val.setUTCMinutes(date.M);
	val.setUTCSeconds(date.S);
	return val;
}

ssf

Format data using ECMA-376 spreadsheet Format Codes

Apache-2.0
Latest version published 4 years ago

Package Health Score

67 / 100
Full package analysis