How can I use the Platform package inside a NgModule conditional?

I have my project running on IOS and Android with capacitor/push-notifications, and I want to add the web version as PWA with Web Push Notifications.
I have two questions:
Registering the ServiceWorkerModule in the App Module of my ionic project, doesn’t it affect the native versions? That is, when I generate
ionic capacitor build android --prod
I will not see problems or interferences with capacitor/push-notifications?
Is there a conditional way to ignore these imports (registers) on mobile versions?

I mean:

@NgModule({
  imports: [
      ServiceWorkerModule.register('worker-sw.js', {
          enabled: !Platform.is('hybrid')
}),...