function getStaticPropertyName(node) {
	let property;

	switch (node?.type) {
		case 'MemberExpression': {
			property = node.property;
			break;
		}

		/* c8 ignore next 2 */
		case 'ChainExpression': {
			return getStaticPropertyName(node.expression);
		}

		// Only reachable when use this to get class/object member key
		/* c8 ignore next */
		case 'Property':
		case 'MethodDefinition': {
			/* c8 ignore next 2 */
			property = node.key;
			break;
		}

			// No default
	}

	if (property) {
		if (property.type === 'Identifier' && !node.computed) {
			return property.name;
		}

		const staticResult = getStaticValue(property);
		if (!staticResult) {
			return;
		}

		return String(staticResult.value);
	}
}
Gets the property name of a given node.
The node can be a MemberExpression, a Property, or a MethodDefinition.

If the name is dynamic, this returns `null`.

For examples:

	a.b		   // => "b"
	a["b"]		// => "b"
	a['b']		// => "b"
	a[`b`]		// => "b"
	a[100]		// => "100"
	a[b]		  // => null
	a["a" + "b"]  // => null
	a[tag`b`]	 // => null
	a[`${b}`]	 // => null

	let a = {b: 1}			// => "b"
	let a = {["b"]: 1}		// => "b"
	let a = {['b']: 1}		// => "b"
	let a = {[`b`]: 1}		// => "b"
	let a = {[100]: 1}		// => "100"
	let a = {[b]: 1}		  // => null
	let a = {["a" + "b"]: 1}  // => null
	let a = {[tag`b`]: 1}	 // => null
	let a = {[`${b}`]: 1}	 // => null
@param {ASTNode} node The node to get.
@returns {string|undefined} The property name if static. Otherwise, undefined.