Skip to content

Instantly share code, notes, and snippets.

@AndrewRayCode
Created September 30, 2015 01:50
Show Gist options
  • Select an option

  • Save AndrewRayCode/6e10bfa8a1300761ffd3 to your computer and use it in GitHub Desktop.

Select an option

Save AndrewRayCode/6e10bfa8a1300761ffd3 to your computer and use it in GitHub Desktop.
let conflicts = _.chain( shaders ).reduce( ( memo, shader ) => {
return memo.concat(
shader.runtime.metadata.fragment.variables,
shader.runtime.metadata.vertex.variables
);
}, [] ).countBy().reduce( ( memo, countGroup, name ) => {
if( countGroup > 1 ) {
memo.push( name );
}
return memo;
}, [] ).value();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment