Chinese officials say locals from the country's troubled western region of Xinjiang have joined the Islamic State group (IS).

Zhang Chunxian, the region's Communist Party chief, said authorities have discovered a group of individuals who were plotting violent attacks on Chinese soil after being trained by Islamic State militants.

His comments on the sidelines of China's annual parliamentary session in Beijing is the first time officials have linked Chinese citizens with IS militants.

Mr Zhang did not say how many people were believed to have been involved in terror plots on home soil.

The Chinese government, which had previously expressed concern about the rise of IS, said it was drafting a national security law, anti-terrorism law and cyber security law.

The move follows a report in the state-run newspaper Global Times in December, claiming that about 300 Chinese nationals were fighting with IS in Iraq and Syria. The article did not name the source of its information.

Xinjiang, traditionally home to Turkic-speaking ethic Uighurs, is the focus of the Chinese government's anti-terrorism campaign because of the high level of violence in the province over the last two years.

These deadly attacks are often targeted at the local authorities.

They took a rare turn in late 2013 when a vehicle with a black flag deliberately drove into civilians on the sidewalk by Tiananmen Square.

China's official Xinhua news agency said the flag had "extreme religious references".

There have been subsequent knifing and bombing attacks in Kunming and Urumqi.

Shohrat Zakir, vice party secretary of Xinjiang Uygur Autonomous Region, said security in the province was under control as many cases of terrorism had been nipped in the bud.

The government blames these attacks on separatists who are part of the so-called East Turkestan Islamic Movement.

Rights groups point to economic inequality and cultural and religious repression of Uighurs as drivers of unrest in the vast and resource-rich region.

Uighur activists claim racial tensions between Uighurs and Han Chinese are being worsened by discrimination.

Beijing has pledged to deepen investment in education and infrastructure in Xinjiang, particularly in the south where most of the attacks have occurred, as a way of addressing ethnic tensions.

ABC