add console.log functionality

Solves #12