WEB IDE - separate functions into own tabs

Hi All,

Is it possible to use the tabs in the IDE to group functions together and separate into tabs like the arduino IDE?

Can this be done without setting up a class, which is how this was achieved in the following topic? [SOLVED] How to use additional files (.c and .h) with .ino file (Particle desktop IDE)

Absolutely. You can delete the .cpp file and use just the .h file.

example.ino:

#include "lib1.h"

void setup() {
    Serial.begin(115200);
    myFunction("hello world");
}

void loop() {   
}

lib1.h:

void myFunction(const char* message) {
    Serial.println(message);
}
2 Likes

Perfect, thanks a million.

1 Like

Hey, totally unrelated, but I can’t help it.

May I suggest you look into using the Particle Workbench?
I’m 99% sure your future self will thank you later. It’s much more convenient than coding on a web browser.
For home projects the WEB IDE is fantastic, but your project and you deserve VS Code. :muscle:

If you have explored it already, please disregard my comment.

3 Likes

You’re entirely right gus.

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.