The ratings should be included with the file when you export it.
Depending on the file type, ratings can also be stored with the original file imported into Lightroom by 'Saving Metadata'. This can be done manually from the Library > Metadata menu, or by pressing Ctrl-S. Additionally, you can set the Metadata to autowrite in the Edit > Catalog Settings menu.
For DNG, JPG, TIF and PSD original files, the metadata will be saved within specific standardaized sections of the files. For raw types, a secondary companion 'sidecar' file will be created with the same name as the original file and filetype *.XMP.
Note that metadata standards, of which ratings are a part, are continually being revised, as well as software that uses them. So incompatibilities of metadata sharing/processing between various programs often arise. You more or less have to try things out as you go.
When you say "is the work lost....", are you specifically referring to the ratings? Or to all of the Lr capabilities in general, because that's a pretty wide subject.