We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
1- How to run only one test ?
2- Meaning of this code in ApiTest ?
public Match(final String[] lines) { super("jsjenerator-matcher"); this.lines = lines; }
3- What happens if we have 2000 divs ? The program goes from 0 to 999 as you can see 03d. Should we not start at 001 instead of 000 ? #239 #240
public class TypeBasedVariableNameStrategy implements VariableNameStrategy { private final Map<String, AtomicLong> counters = new HashMap<>(); @Override public String nextName(@NonNull String type) { // NOTE: issue#145 careful with custom element about casing and dash, not to translate in JavaScript identifiers var identifier = type; final var HAS_DASH = type.contains("-"); final var IS_ROOT = "targetElement".equals(type); final var HAS_UPPER_CASE = !type.chars() .allMatch(character -> Character.toLowerCase(character) == character); if (!IS_ROOT) { identifier = HAS_UPPER_CASE ? type.toLowerCase() : identifier; identifier = HAS_DASH ? type.replaceAll("-", "_").replaceAll("_+", "_") : identifier; if (HAS_DASH || HAS_UPPER_CASE) { identifier = "custom_%s".formatted(identifier); } } return format("%s_%03d", identifier, counters.computeIfAbsent(type, __ -> new AtomicLong()).getAndIncrement()); } }
The text was updated successfully, but these errors were encountered:
#235
Sorry, something went wrong.
#238
No branches or pull requests
1- How to run only one test ?
2- Meaning of this code in ApiTest ?
3- What happens if we have 2000 divs ? The program goes from 0 to 999 as you can see 03d. Should we not start at 001 instead of 000 ? #239 #240
The text was updated successfully, but these errors were encountered: