Did you mean to use a ':'? An '=' can only follow a property name when the containing object literal is part of a destructuring pattern. react-router-dom code example
Example 1: mdn destructuring
let a, b;
[a, b] = [1, 2];
console.log(a); // 1
console.log(b); // 2
Example 2: js object destructuring
const { [propName]: identifier } = expression;