Can't comment to much about the Twisted Treeline as I don't play that game mode all that much so my advice is mostly for facing her in Summoner's Rift, which can probably translate to TT as well though.
For starters, Pre-level 6 her entire combo and trading potential is all on her Q. Until she can get her ultimate, that Q is everything, where if you dodge it...you basically win any trade against her pre 6 since without that she literally does almost 0 damage. Try to see how she plays, pre6 Anivia would like to step up closer to you to get a closer ranged Q on you, and it's very easy to read. You might think Anivia's would throw out their Q from far range since it is like 1100 range but her actual damage comes from her E which is only like 600-700, so she would always step up within that range before using her Q. If you see her walk up closer when she's pre6, chances are that she is getting in range to Q you. If you dodge it, then just jump on her and punish her.
Push her to her tower. While Anivia has god like wave clear, that is only when she has her ultimate...but Pre-6, Anivia's wave clear is actually terrible and she will easily miss most of the minions under tower. Even when she reaches level 6, her ultimate really takes a lot of mana out of her and can go oom super quickly if she is not careful. With all the rune changes to Manaflow Band and Presence of Mind, her mana in lane has been hurt even more...though her Mid/Late game mana management has been made better. But if you want to take a huge advantage against her, then play a mage who can wave clear extremely well that cost a lot less mana, and bonus if they also have great poke. People like
can make Anivia's life hell when used right.
Post 6 is when Anivia can be a lot more aggressive. Anivia would probably walk up to you and drop ultimate under you and then put a wall behind you to block your escape until the ultimate reaches full size to hit you with an E. If you have any reliable CC, then save that CC for when she drops her ult + wall on you, and instantly hit her with that CC. That way you can make her waste all that mana for using her ult and wall (which easily adds up) and now her wall is on CD for 17 seconds. Losing wall is huge as it's one of her best and reliable ways to keep you in her ultimate (outside of Q ofc) and her main way to escape from ganks etc.
Be careful on Anivia's Q as well. Depending on who you are playing, Anivia will save her Q for when you jump in. Say for example,
is an annoying match up for Anivia, and Anivia would have to save her Q for when Leblanc Distortions in, otherwise it's super easy for her to kill Anivia and dodge around her skills. If you are playing a champion who has strong burst and mobility, then Anivia may be saving her Q for when you jump on her and would just rely on her Ult + wall + E to trade with you. If she uses her Q on you, then dodge it and instantly go aggressive on her.
If you force her into her egg, then try to kill it if you can, but don't overstay for that kill if you are afraid of dying (to either her reborning before, or jungler gank etc). Even if you only got her egg, count that as a win and back off. Her egg is a 4 minute CD so that would be a huge win in itself anyways, and then you know when your ultimate comes back, you can just rejump on her knowing she wouldn't have it then. Think of it as when you are playing ADC and the opponent has a
. Even just getting that is pretty huge in that instance, and Anivia's egg is similar to that.