namingConventions
Override source and destination naming conventions for one mapping.
createMap(
mapper,
User,
UserDto,
namingConventions(new CamelCaseNamingConvention()),
);
Use separate conventions when the source and destination differ:
createMap(
mapper,
ProductRow,
ProductDto,
namingConventions({
source: new SnakeCaseNamingConvention(),
destination: new CamelCaseNamingConvention(),
}),
);
Mapping-level configuration overrides the convention supplied to createMapper() or addProfile(). See Naming conventions for mapper- and profile-level examples.