adding code block functionality