Visual Micro without .ino files
Make a new tab in the IDE (top RH corner) with a xxx.cpp file name. Put your code in that. Leave the .ino file blank. Then it will compile. You need to add:



#include &lt;Arduino.h&gt;


... to the start of the .cpp file.

More information: How to avoid the quirks of the IDE sketch file pre-preprocessing



To clarify the question about libraries ...

You do need to put into the .ino file an include for any libraries used in the project. For example:

#include &lt;Wire.h&gt;
#include &lt;SPI.h&gt;
#include &lt;EEPROM.h&gt;


This effectively triggers the Arduino build process to link those libraries into the final executable file.

Related, my reply in this thread: Classes and objects: how many and which file types do I actually need to use them?