code: public String css(String identifier)
      {
          try {
              return new CSSIdentifierSerializer().serialize(identifier);
          } catch (IllegalArgumentException e) {
              LOGGER.warn("Failed to escape CSS identifier. {}", e.getMessage());
              return null;
          }
      }
docs: Escapes a CSS identifier.
  <p>
  See https://drafts.csswg.org/cssom/#serialize-an-identifier.
  </p>
  
  @param identifier the identifier to escape
  @return the escaped identifier
  @since 6.4.7
  @since 7.1.4
  @since 7.4M1