I have an editor and I'm using PygmentsLexer to lex my file but this ends up with slow start speeds for my application. I'm using asyncio and each time I start my application with the layout attached the app takes 1 second to start, with 0.30 seconds taken by the PygmentsLexer.
What can I do to optimize this? Maybe there's a way to create the lexer after my app starts?