MCPcopy Create free account
hub / github.com/nwutils/nw-sample-apps / addLineNumbers

Function addLineNumbers

webgl/js/three.min.js:20826–20841  ·  view source on GitHub ↗
( string )

Source from the content-addressed store, hash-verified

20824 };
20825
20826 function addLineNumbers ( string ) {
20827
20828 var chunks = string.split( "\n" );
20829
20830 for ( var i = 0, il = chunks.length; i < il; i ++ ) {
20831
20832 // Chrome reports shader errors on lines
20833 // starting counting from 1
20834
20835 chunks[ i ] = ( i + 1 ) + ": " + chunks[ i ];
20836
20837 }
20838
20839 return chunks.join( "\n" );
20840
20841 };
20842
20843 function getShader ( type, string ) {
20844

Callers 1

getShaderFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected