.txt file hosted by .pdf

Is there any possibility to add .txt file to .pdf file in a way that text document will be possible to open directly from .pdf file?
But I don't want to add it as attachment, I want it as an element (like .jpg is).

If I attach .txt in .docx and then convert .docx to .pdf, this .txt file is saved as a picture and only .txt icon is seen.

This website is not affiliated, owned, or endorsed by Microsoft Corporation. It is a member of the Microsoft Partner Program.