Best way, IMHO▸ to visit Caernarfon is National Rail to Llandudno Junc, Conway valley to Blaenau Ffestiniog then take Festiniog Line to Portmadog then WHR to Caernarfon, stay a couple of nights.
To return WHR back to Porthmadag then Coast line via Barmouth to Shrewsbury and onwards home.
Note: Coast line is shut at time or posting.
On the date I have planned, after an overnight stay in Lladudno, the best option to do the WHR and FR in one day is to start at Caernarfon at 1000 (bus from Llandudno). This allows a decent break in Portmadog for lunch, then the 1335 to Blaenau to connect with National Rail to Llandudno Junction, then home. Going the other way, starting at Llandudno Junction, the connections are less good and there would only be a 20 minute break in Porthmadog between the two narrow gauge trips.
Trip on Snowdon Muntain Railway is then on cards.
Won't be visiting the Snowdon Mountain Railway. I have a policy of avoiding anywhere I know of that employs the parasites that are ParkingEye to 'manage' their car parks. Recently on the SMR, ParkingEye invoiced a user of the car park after he returned 1 hour 23 minutes late to his vehicle following an accident where he injured himself on the mountain. No compassion when he appealed to ParkingEye. They still want their ^100 for that 83 minutes. SMR refused to intervene.
Edited to correct overstay time. 1 hour 23 minutes, not 23 minutes.