Getting out is always the best option, but, having said that, I once had a fire under the bonnet in one of my old mk1s caused by a broken(and brand new) jubilee clip on a fuel line. Pulled in to the pub car park, which was really handy, and stuck a really small and half used bcf extinguisher up from under the front valance and used it all up AND put it out! wiring was a bit singed but still OK. Put a spare clip on it and carried n to work 😌
So, I guess if you're out, having a go is better than ending up with a burnt out wreck, especially if you've sweat tears and blood into building it.....
BCF wasn't illegal in those days