Download Visual Studio Code
Go to Extensions Tab (⇧⌘X)
Type p5
Find p5.vscode and install
Also, find p5canvas and Install
Command Pallete (⇧⌘P)
Create p5.js Project
Click p5canvas in the bottom right corner
You can use a canvas in Visual Studio Code.
Or click the Go Live button and use a safari.
It'll be refreshed when you save your sketch in Visual Studio Code. And if you want to see the console log, Go to Safari - Develop and click the Show Web Inspector (⌥⌘I)