How to determine the OS path separator in JavaScript?

Use path module in node.js returns the platform-specific file separator.
example

path.sep  // on *nix evaluates to a string equal to "https://stackoverflow.com/"

Edit: As per Sebas’s comment below, to use this, you need to add this at the top of your js file:

const path = require('path')

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)