QR Code to SPA best practice?

Hello, I am planning on creating an app to log various schedules for a classroom. Each classroom has a QR code attached to the wall. When someone scans the QR code, they are redirected to the page for that room. What would be the best practice and guide to doing so? Would it be to send parameters to the page after the QR code is scanned?

Yes URL parameter would be fine. The QR code can be https://[domain]/[pagename]?c=[classroom unique id]

Then on page reference that parameter c