Luxon date library has a DateTime
type. Instead of importing DateTime directly from luxon
library like import { DateTime } from 'luxon';
I would like to extend the library to use a custom type that can be used through out in the project components and this would enable us to replace the third party library in one place in the future with another if needed.
First question: Is there any easy way to do this without custom extending the library? if not then would it be possible to use the same name? (AFAIK no)
export interface {CustomPrefixName}DateTime extends DateTime {
}
This works but any way to get rid of prefix name?
then then import custom datetime in components
import { CustomDateTime } from 'somewhereInProject';