I agree that after tax contributions are generally best used for mega backdoor Roth as investing in taxable (with favorable long term capital gains taxation) is usually better than investing in after tax (in which gains are taxed at ordinary income tax rates when withdrawn), with a couple of caveats:
1) It was recently pointed out to me on Bogleheads that leaving money in after tax can be preferable to investing in taxable if you invest in bonds in that account as bond interest is taxed at ordinary income tax rates no matter what, and in after tax you can defer until you're in a lower tax bracket.
2) Since you'll be leaving employment in a few years anyway, at which point you can roll over principle to Roth and gains to traditional without paying tax at the time of rollover, you'll only be a little worse off than if you could make immediate rollovers through in-service withdrawals.
That said, making the rollover to Roth IRA or making an in plan conversion to Roth 401(k) while still working would definitely be the best option, so do that if you can.