A lot of codesnippets made for a specific microcontroller board are compatible with others: The only change needed to make would be the pins. Make sure the used libraries are compatible with the board you are trying to use them on.
Codesnippets for different microcontroller boards.
Learn about the ESP32 microcontroller board.
Learn about the Arduino Uno R4 WiFi microcontroller board.
Learn about the Arduino Uno R4 Minima microcontroller board.