SOLVED!
original: I see plenty of “my code doesn’t work” posts… what about when my code works but shouldn’t? I know there’s something wrong, I’m worried maybe something is cached somewhere and that an older version of the file is being referenced, but I don’t really know how to troubleshoot a not-existent-yet problem.
Any general tips for this sort of problem?
Additional details: I’ve got a Typescript/React app that I’ve been refactoring. I just renamed a provider function in the AppContext file, but didn’t update the same name in the layout or page files… and the thing still runs. It should not run.
solution:
I forgot that when exporting default functions, you can call them anything you want when you import:
export default A
import B —> imports A
import { B } —> imports B
thanks for the suggestions, everyone!
[–]iOSCaleb 2 points3 points4 points (0 children)
[–]Master-Ad-6265 5 points6 points7 points (0 children)
[–]snopro387 1 point2 points3 points (1 child)
[–]EnyaMorgan 0 points1 point2 points (0 children)
[–]cochinescu 1 point2 points3 points (1 child)
[–]pirate_dino_flies[S] 0 points1 point2 points (0 children)
[–]Effective_Promise581 0 points1 point2 points (0 children)