If you want a 1x drivetrain, its best to use a narrow-wide chainring and a rear derailleur with a clutch. Otherwise the chain might come off frequently. If you dont mind that, eg if this is your old commuter bike, you can just take the front derailleur off.
Alternatively, if its a problem with the cable, could you run it differently, eg in external housing or use longer ferrules to guide it?
IME a narrow-wide chainring is a must, clutch mech less so. I’ve had dropped chains when using a clutch and no NW chainring but never with a NW and no clutch.
If you stay with the same cassette then you’ll have much less range, it’s why MTB 1x systems have such large wide ratio cassettes. Use http://gear-calculator.com/ to figure out what will be a suitable range for your usage. If you do fit a larger range cassette make sure that your rear mech can handle it. Shimano are conservative with their max recommendations, I’ve never had problems going 2T higher and have gone 4T higher with a bit of care. Don’t know about Sram.
Up front it isn’t just a case of removing the chainrings and fitting a single NW one in their place, you’ll need to work out the best chainline. With a 1x setup this will always be a compromise in that there’ll be some high chain deflection at one end of the range or the other. I tend to set things up slightly biased towards the low end as it stresses the rear mech a little less but does depend on your usage, if you don’t use the low gears much then set it up with a high end bias. It’s only 2-3mm or so either way.