An electrochemical sensor based on the modification of platinum nanoparticles and ZIF-8 membrane for the detection of ascorbic acid.