js log snippet