I've been looking quite a bit and it's near impossible to find a 340ohm resistor though the 330ohm ones are easily available. Would that be ok as a replacement?
stated already, 330 Ohm should be fine.
Usually, when you calculate a resistor, you go with the nearest lower standard value. The reason for 340 Ohm mentioned somewhere, might simply be that the designer didn't think too much about who would use the design and so used what he/she had lying around already.
Unless it's for something with critically defined voltage levels or similar, it won't matter because 10 Ohm in 340 Ohm is 10*100/340 = 2.9% and the standard resistors you will use is 5% tolerance, meaning that a 340 Ohm resistor can be from 323 Ohm to 357 Ohm while still being within tolerance.
Btw, I'm also concerned about my breadboard and breakaway male connector not being RoHS compliant. Are there any precautions I should be taking?
The RoHS directive is to lessen the amount of lead in waste dumps and land fills, not to protect you and that shouldn't worry you, as humans cannot assimilate heavy metals in their metallic form.