Is there any difference between writing a literal string in single or double quotation marks?
Example:
var s = 'texto';
// ou
var s = "texto";
Is there any difference between writing a literal string in single or double quotation marks?
Example:
var s = 'texto';
// ou
var s = "texto";
There may be cases where one is more practical, for example:
var stringA = 'Olá Mc\'Neil';
var stringB = "Olá Mc'Neil";
console.log(stringA, '|', stringB); // Olá Mc'Neil | Olá Mc'Neil
In other languages how PHP is different.