I’m using ESP8266 with Softserial to UNO, so I cannot give you the code of node MCU but I can give you the idea.
If you see, Blynk use Blynk.bigin (auth, ssid, pass) to initialize the connection.
All we have to do is split Blynk.being() into WiFI manager part and Blynk connection part. Here how I have done.
//Original sketch
// Blynk.begin (auth, ssid, pass);
// modify sketch
##include <SoftwareSerial.h
#include <BlynkSimpleShieldEsp8266.h
SoftwareSerial EspSerial(3, 2); // RX, TX
ESP8266 wifi(&EspSerial);
Blynk.config(wifi, auth);
// Process any wifi code here, e.g. Wifi config to get the correct ssid, pass
String APlist = wifi.getAPList ();
Serial.print (“AP List:”);
Serial.println (APlist);
GetwifiInfo (&ssid, &pass);
Blynk.connectWiFi (ssid, pass); // connect to wifi network
String resulttext = wifi.getLocalIP();
if (resulttext .startsWith("+CIFSR:STAIP,")) { // wifi connect success
Serial.print ("Connected to ");
Serial.println (ssid);
while(Blynk.connect() != true) {} // Blynk.connect() has time-out handling
if (Blynk.connected()) {
Serial.println (“Blynk connected.”);
}
}
hope this help