Is there any way to find out the type of block without breaking it?

  1. In creative mode you can use the Pick Block keybind (middle mouse button) to put the block in your hand
  2. The debug (F3) menu displays which block you're looking at

Note that method 1 will work in survival if you have the block in your inventory