Extract the core code related to Path2D, PathStrore, and isPointInPath from Skia and rewrite it with typescript