Former Sonar X user here. Got my wife's Macbook Air after she got an iPad.
I have a 2012 Macbook Air (i5 1.8, 8, 256) that I use as my primary computer. I have a 27" monitor at my home-studio. For my projects, using the Air and Logic Pro X works for me. I have about 20-25 tracks of audio plus a few tracks of loops/synths. I connect my TASCAM US-1800 to the Air via USB and an additional USB hub with a mouse/keyboard/external HDDs which connects to the Air's other USB port. I connect my external LCD to the Thunderbolt port using an TB-DVI converter.
I do not have any problems recording on this system. No system-related dropouts. No running out of memory. I have at least two projects that are 5GB in project size. I have no problems loading them on the Air. I have been using this setup for about 14 months.
My home studio needs are small however. I record drums, guitars, vocals, bass and edit them using Logic. I only record a track at a time unless I'm recording drums in which case I'm recording 8 tracks at once.
The system is responsive and doesn't crash or have "Disk not fast enough" or other related errors. There is no lag, stuttering or other audio weirdness.
For a performance example, it takes about 25 seconds to load up my 6m45s 5.71GB project. I timed this to compare it to the same project file loading on a friend's mackintosh (i5 3.2GHz, 16GB, 256 SSD). On his system it takes 16 seconds to load the same project from a cold boot. Neither system have problems playing this project.
Understand that I write/produce music as a hobby. Therefore ultimate speed/performance is not a concern for me. I enjoy the portability of the Air and the ability to write/record my music on the same machine. You may have different goals.
I use an external HDD to copy my audio files to after a recording session. I also have another external HDD that I use for Time Machine backups. Thus, I have a copy of my music on the Air and essentially two external HDD. I feel that is suffice should the SSD in the Air die, AND I lose an external HDD at the same time.
I use this machine daily and I'm in my studio many times per week.
TL;DR - Yes you can use a Macbook Pro to record using Logic and you won't have a problem. This depends on your needs. There's a reason a professional studio spends $$$ on Mac Pros.. However for a home studio, in my opinion, a Macbook Pro would work well.