How to extend what Registration does?

In the new strapi 4.0, I dont think we can use this anymore…I am trying to put it in /src/index.js…
register({ strapi }) {
const extensionService = strapi.plugin(‘graphql’).service(‘extension’);
extensionService.use(({ nexus }) => ({
types: [
nexus.extendType({
type: ‘UsersPermissionsRegisterInput’,
definition(t) {
// here define fields you need
t.string(‘AndyLai’);
},
}),
]
}));
},

but it doesn’t work…Any help will be appreciated.