Open hildjj opened 1 day ago
Some of the "private" methods are actually mocked in tests, and #
prevents that. I mostly used private
to be consistent, realizing and accepting it's closer to hidden than actually inaccessible.
That said, could consider switching if viable replacement testing comes up.
since you're using Deno and don't have to support old versions of node, you can safely use
#get
instead ofprivate get
. Typescript normally goes through some gyrations to makeprivate
fields/methods private, whereas it's built-in to the runtime with#
.https://github.com/o-p-n/serveit/blob/152c4566d68504350b2de8cac2037c98f20125e6/src/file-server.ts#L41